1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

SSH Find File Command?

Discussion in 'Site & Server Administration' started by NetworkTown.Net, Feb 13, 2008.

  1. #1
    If any one knows the command for ssh to find a file on the server using the file name please post it.

    Thanks in advance.
    SEMrush
     
    NetworkTown.Net, Feb 13, 2008 IP
    SEMrush
  2. Pinoguin

    Pinoguin Peon

    Messages:
    848
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #2
    find /home/username/ -name filename.ext

    *finds the file 'filename.ext' in the /home/username/ directory


    or try the command 'locate'
     
    Pinoguin, Feb 13, 2008 IP
  3. NetworkTown.Net

    NetworkTown.Net Well-Known Member

    Messages:
    2,022
    Likes Received:
    28
    Best Answers:
    0
    Trophy Points:
    165
    #3
    Thanks worked like a charm.
     
    NetworkTown.Net, Feb 13, 2008 IP
  4. adbox

    adbox Well-Known Member

    Messages:
    906
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    155
    Digital Goods:
    1
    #4
    Anyone know how to paginate search results with the find command? Or navigate the output to see passed pages?
     
    adbox, Jun 14, 2011 IP
  5. elicitservers

    elicitservers Peon

    Messages:
    714
    Likes Received:
    7
    Best Answers:
    1
    Trophy Points:
    0
    #5
    Do you mean if you have more results than you can see through SSH? I'm not so sure what you mean, but if I'm correct you can output the command to a text file:
    Then open up the results.txt file in a text editor. Please correct me if this isn't what you were looking for!
     
    elicitservers, Jun 26, 2011 IP
  6. Orangu

    Orangu Active Member

    Messages:
    571
    Likes Received:
    21
    Best Answers:
    0
    Trophy Points:
    60
    #6
    To paginate results use a pipe to either more or less

    find /directorytosearch -name filename.ext | more
    or
    find /directorytosearch -name filename.ext | less

    ByEzz
     
    Orangu, Jun 26, 2011 IP
  7. KolorKode

    KolorKode Greenhorn

    Messages:
    44
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    18
    #7
    locate is great remember to schedule an "updatedb"
     
    KolorKode, Jun 30, 2011 IP