PDA

View Full Version : Cant rename directory in localhost.



CastilleV
January 21st, 2009, 06:48 AM
I installed LAMP a few weeks ago, and moved a folder to the /var/www/ folder.
Only realizing I didn't rename it, and I tried to fix things using the terminal.

Is there some way I can rename it?

amauk
January 21st, 2009, 06:50 AM
mv /path/to/old_name /path/to/new_name

CastilleV
January 21st, 2009, 06:53 AM
mv /path/to/old_name /path/to/new_name

Already tried that, I get a permission denied.

amauk
January 21st, 2009, 06:54 AM
use sudo
(gives you root privileges)

sudo mv /path/to/old_name /path/to/new_name

CastilleV
January 21st, 2009, 06:56 AM
use sudo
(gives you root privileges)

sudo mv /path/to/old_name /path/to/new_name

Hey! :D It worked! Thanks!
Damn confusing terminal! But, its what I like about linux.

Tek-E
February 20th, 2009, 10:08 PM
Question... Why is it you get the same results using the su command?
Is su just a shorter version for sudo?

Tek-E
February 20th, 2009, 10:14 PM
Eeek nevermind. I just looked up the answer. And they arent necessarily the same command. :/ Embarresment!