The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Copy a file with ssh

Discussion in 'General Discussion' started by persianwhois, Aug 6, 2007.

  1. persianwhois

    persianwhois Well-Known Member

    Joined:
    Apr 18, 2007
    Messages:
    117
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Mahallat
    cPanel Access Level:
    Root Administrator
    Hi,
    how can copy a file (i.e. php.ini) to all sub directory of user public_html?
    help me please. :)
     
  2. ddeans

    ddeans Well-Known Member

    Joined:
    Feb 13, 2004
    Messages:
    296
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Maryland
    I am not sure that you can do a mass copy like that for current users. Are you talking about when you are setting up new accounts, or for all the users currently on your server?
     
  3. persianwhois

    persianwhois Well-Known Member

    Joined:
    Apr 18, 2007
    Messages:
    117
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Mahallat
    cPanel Access Level:
    Root Administrator
    I need use mass copy just for one user.
    i.e. copy /home/example/test.php to all subdirectory of /home/user/public_html
    thank you.
     
  4. persianwhois

    persianwhois Well-Known Member

    Joined:
    Apr 18, 2007
    Messages:
    117
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Mahallat
    cPanel Access Level:
    Root Administrator
    Help Meeee .......... :(
     
  5. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,052
    Likes Received:
    2
    Trophy Points:
    38
    Location:
    Earth
    There is no such command to mass copy a file under a users home directory recursively. You will have to write a script for that.
     
  6. verdon

    verdon Well-Known Member

    Joined:
    Nov 1, 2003
    Messages:
    836
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Northern Ontario, Canada
    cPanel Access Level:
    Root Administrator
    Just to be sure...

    are you looking to put a copy of example.php in every user's public_html directory, OR

    are you looking to put a copy of example.php in every sub-directory under a specific user's public_html directory?
     
Loading...

Share This Page