Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

i have a problem with command tar

Discussion in 'General Discussion' started by mados, Feb 17, 2009.

  1. mados

    mados Member

    Joined:
    Jun 27, 2007
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    51
    hello

    i have a problem with the command tar , when i am try to unzip any file this error appears

    Code:
    -bash: tar: command not found 
    plz help me
     
  2. Voltar

    Voltar Well-Known Member

    Joined:
    Apr 30, 2007
    Messages:
    267
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    Bakersfield, California
    What OS are you using?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. mados

    mados Member

    Joined:
    Jun 27, 2007
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    51
    hello

    Linux
     
    #3 mados, Feb 17, 2009
    Last edited: Feb 17, 2009
  4. don_will

    don_will Well-Known Member

    Joined:
    Jun 26, 2007
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    56
    Location:
    Cpanel
    try : rpm -q tar

    if you cannt see like this : tar-1.15.1-23.0.1.el5

    try yum update or yum install tar

    and make sure you type the cmd like ... tar -zxvf file.tar.gz e.t.c
     
  5. Voltar

    Voltar Well-Known Member

    Joined:
    Apr 30, 2007
    Messages:
    267
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    Bakersfield, California


    Try executing:

    Code:
    which tar
    And

    Code:
    whereis tar
    And see if they turn up anything.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. mados

    mados Member

    Joined:
    Jun 27, 2007
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    51
    i did what you told me but i does not work

     
  7. Zishan

    Zishan Well-Known Member

    Joined:
    Aug 6, 2005
    Messages:
    104
    Likes Received:
    1
    Trophy Points:
    168
  8. mados

    mados Member

    Joined:
    Jun 27, 2007
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    51
    i do it but it still not working

     
  9. WebScHoLaR

    WebScHoLaR Well-Known Member

    Joined:
    Dec 14, 2005
    Messages:
    511
    Likes Received:
    3
    Trophy Points:
    168
    Location:
    Planet Earth
    tar is already installed on the server. Please provide me the output of following commands:
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  10. mados

    mados Member

    Joined:
    Jun 27, 2007
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    51
    hello
    here the output

    Code:
    root@server1 [~]# rpm -q tar
    tar-1.14-12.5.1.RHEL4
    root@server1 [~]# whereis tar
    tar: /usr/include/tar.h /usr/share/man/man1/tar.1.gz
    root@server1 [~]# echo $PATH
    [/home/[COLOR="Red"]user[/COLOR]/DigiChat_4.0/jdk1.5.0/bin:/usr/local/jdk/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/lib/courier-imap/sbin:/usr/lib/courier-imap/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/local/bin:/usr/X11R6/bin:/root/bin
     
    #10 mados, Feb 17, 2009
    Last edited by a moderator: Feb 17, 2009
  11. johny_gjx

    johny_gjx Active Member

    Joined:
    Apr 15, 2005
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    156
    Does /bin/tar work for you?

    Code:
    /bin/tar --help
    if the above does not work then do
    Code:
    rpm -e tar-1.14-12.5.1.RHEL4
    rpm -i [url]http://mirror.centos.org/centos/4.7/os/i386/CentOS/RPMS/tar-1.14-12.5.1.RHEL4.i386.rpm[/url]
     
    #11 johny_gjx, Feb 17, 2009
    Last edited: Feb 17, 2009
  12. mados

    mados Member

    Joined:
    Jun 27, 2007
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    51
    emmmm

    no it dose not work

    it dose not exist

     
    #12 mados, Feb 17, 2009
    Last edited: Feb 17, 2009
  13. sparek-3

    sparek-3 Well-Known Member

    Joined:
    Aug 10, 2002
    Messages:
    1,798
    Likes Received:
    131
    Trophy Points:
    343
    cPanel Access Level:
    Root Administrator
    If I had to guess, it looks like tar has been deleted from your server. I don't know if this was done intentionally or accidentally by an admin on your server or if your server has been rooted.

    Run the command:

    Code:
    rpm -ql tar
    and see where tar is suppose to be installed at. If it lists /bin/tar then tar has been deleted from your server.

    You might reinstall it by running:

    Code:
    yum remove tar
    yum install tar
    though you should really investigate the reason why tar was removed in the first place.
     
  14. mados

    mados Member

    Joined:
    Jun 27, 2007
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    51
    hello

    now i remove it by your commands and reistall it and its work good now

    on other hand my server does not rooted and when i reinstall the tar it posted in the same palce

    thank you alot for help

    best regards
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice