Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
01-30-2006, 09:30 PM
|
#1
|
Member
Registered: Sep 2004
Location: Navi Mumbai
Distribution: Ubuntu 14.04 64-bit
Posts: 230
Rep:
|
Unable to locate in bash
I had uploaded a test.zip to public_html/test folder using FileZilla. Couldnt use WinSCP as it was hanging for this server.
I can get in through Putty though but cannot seem to find the file test.zip's path.
Code:
-bash-2.05b$ locate test.zip
warning: locate: could not open database: /var/lib/slocate/slocate.db: Permission denied
warning: You need to run the 'updatedb' command (as root) to create the database.
-bash-2.05b$
Any ideas whats wrong here ?
Thanks
|
|
|
01-30-2006, 09:54 PM
|
#2
|
Senior Member
Registered: Jan 2004
Location: Roughly 29.467N / 81.206W
Distribution: OpenBSD, Debian, FreeBSD
Posts: 1,450
Rep:
|
Quote:
You need to run the 'updatedb' command (as root) to create the database.
|
Have you tried this?
|
|
|
01-30-2006, 10:14 PM
|
#3
|
Member
Registered: Jan 2006
Location: Brisbane, Australia
Distribution: Suse, Mandrake, IPCop, Debian, Slackware
Posts: 34
Rep:
|
As frob23 said, you should try that command. It should solve your problem.
However, if your just locating it, have you tried:
$ ls -l /home/(your username)/public_html/test
I can't remember if it is in the home directory or if it is in, say, apache's.
|
|
|
01-30-2006, 10:33 PM
|
#4
|
LQ Guru
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733
|
If I understand the question, you used an ftp client to "put" a file in a remote server's <your account>/public_html/ folder. You could try ftp'ing into the account and using "ls" or "dir" to see if the file is there. If you have secure shell access then you can use the secure shell, cd to the folder and list the contents. There is also the find command.
If this is a remote server, and you don't have root access, you won't be able to run "updatedb" as root. On some systems, this command is run as an imaginary user named "nobody" who has very limited rights, and the locate command may not list your files, unless any other user can also view your files.
I hope my assumptions are correct.
Last edited by jschiwal; 01-30-2006 at 10:35 PM.
|
|
|
01-30-2006, 10:46 PM
|
#5
|
Member
Registered: Sep 2004
Location: Navi Mumbai
Distribution: Ubuntu 14.04 64-bit
Posts: 230
Original Poster
Rep:
|
Quote:
Originally Posted by matthalliday
$ ls -l /home/(your username)/public_html/test
|
Thanks - this was the location alright !
|
|
|
All times are GMT -5. The time now is 07:08 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|