LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-23-2003, 09:34 PM   #1
drxsmurf
Member
 
Registered: Oct 2003
Location: Texas
Distribution: Mandrake 9.2, Slackware 10.0
Posts: 51

Rep: Reputation: 15
Wow this is annoying


OK...trying to install wine, i screwed up and want to start over. I want to start over all the way from the beginning. So i go to delete the source tree so i can re-tar the tarball file and start from scratch. when i try to delete the wine20031016 directory in KDE, it doesn't work, telling me that i dont have the permissions to do it. when i use Konsole, logged in as su, i tried using the rmdir and the rm commands, both of which returned the same error: "cannot remove directory wine-20031016: file is a directory"

What am i supposed to do here?
 
Old 10-23-2003, 09:40 PM   #2
jrdioko
Member
 
Registered: Oct 2002
Distribution: Debian 6.0.2 (squeeze)
Posts: 944

Rep: Reputation: 30
I believe "rmdir" deletes empty folders and "rm -r" removes folders with things in them.

-JMagi
 
Old 10-23-2003, 09:40 PM   #3
wapcaplet
LQ Guru
 
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Rep: Reputation: 48
In Linux, like its Unix predecessors, you can't use rmdir or rm on a directory that still contains files, or other directories. The easiest thing to do is tell rm to remove files recursively. Open up a console, become root if necessary, and do:

rm -rf /path/to/wine-20031016

Also, in order to cut down on the number of times you have to become root, it may be good to un-tar and compile programs as a normal user. Set a directory somewhere that the user has write permission to, and do all your compiling there. That way, you don't need to become root to delete an old source tree. You can also run configure, make, and many other things as a normal user - then just become root to 'make install'.

p.s. - be very careful with the 'rm -rf' command, especially when you are root! If you rm -rf the wrong directory, you might wipe out your hard drive. The '-f' means 'force', which means it won't ask for any confirmation about deleting things. All the more reason to do most of that stuff as a normal user, if possible.

Last edited by wapcaplet; 10-23-2003 at 09:42 PM.
 
Old 10-23-2003, 10:01 PM   #4
drxsmurf
Member
 
Registered: Oct 2003
Location: Texas
Distribution: Mandrake 9.2, Slackware 10.0
Posts: 51

Original Poster
Rep: Reputation: 15
Wow, thanks that did it. I appreciate the incredibly fast reply
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
wow, im here now xpression Linux - Newbie 5 09-09-2005 05:33 PM
Wow... RoaCh Of DisCor Slackware 19 09-15-2004 02:04 PM
Well all I can say is.... WOW! perry Linux - Hardware 0 07-25-2004 01:16 AM
Wow LinuzRulz General 1 04-23-2002 11:13 PM
wow wow wow acid_kewpie Linux - General 1 01-22-2002 05:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:43 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration