Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I've a file called piture-list.php in my website.

When I see them through the ftp client it shows two files with different filesizes.

as

File name          filesize
picture-list.php   19818
picture-list.php   9063

When I select the file with filesize 9063 and delete using ftp, it deletes the file with the filesize 19818.

Then I used the command prompt to list files and happened to see actually there were two files one with the original name and other with a space before the filename (" picture-list.php").

I tried to move, delete the file but nothing is successful..

What may be the issue?

share|improve this question

1 Answer 1

up vote 3 down vote accepted

To interact with the file containing a leading space you will need to put a quotes around the file name e.g.

rm " picture-list.php"

You can also use the -i command line switch e.g.

rm -i *pict*
rm: remove regular file ` picture-list.php'?

and answer y to remove the one with the leading space.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.