LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 08-05-2009, 01:17 AM   #1
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 539

Rep: Reputation: 33
How to remove a symbolic link?


Hi,

I make a symbolic link with:
ln -s /var/log/jboss/test/log

Now I want to delete or remove this symbolic link. I use the following command:
rm -rf /var/log/jboss/log

But as I use the ls -l to check, this symbolic link is still there:

log -> /var/log/jboss/test/log


Someone has idea?
 
Old 08-05-2009, 01:19 AM   #2
thomas2004ch
Member
 
Registered: Aug 2009
Posts: 539

Original Poster
Rep: Reputation: 33
I solve the problem. I do as follow:

rm log
 
Old 08-05-2009, 01:58 AM   #3
ThinkFree
Member
 
Registered: Jan 2009
Location: India
Distribution: Fedora, Arch, OpenSolaris
Posts: 112

Rep: Reputation: 20
Quote:
Originally Posted by thomas2004ch View Post

I make a symbolic link with:
ln -s /var/log/jboss/test/log
I think this will create a broken link
 
Old 08-05-2009, 02:39 AM   #4
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
Quote:
Originally Posted by thomas2004ch View Post
Hi,

I make a symbolic link with:
ln -s /var/log/jboss/test/log

Now I want to delete or remove this symbolic link. I use the following command:
rm -rf /var/log/jboss/log

But as I use the ls -l to check, this symbolic link is still there:

log -> /var/log/jboss/test/log


Someone has idea?
Code:
ln -s /var/log/jboss/test/log
Aren't you missing an argument here? what are you linking this to?
jdk.
 
Old 08-05-2009, 05:25 AM   #5
davidshen84
LQ Newbie
 
Registered: Feb 2009
Posts: 8

Rep: Reputation: 0
have you tried unlink?

unlink your_sym_link
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Cannot remove symbolic link to directory. martint Linux - Newbie 6 09-17-2014 08:45 PM
How to create symbolic link to html file and avoid page link problem? haxpor Linux - General 2 01-29-2008 07:40 AM
How to remove a symbolic link without deleting the file rhbegin Fedora 4 10-10-2007 10:38 AM
Is there a way to remove a symbolic link Philter Linux - Newbie 3 11-30-2004 06:24 PM
Can't remove symbolic link kimchee411 Linux - Newbie 1 10-06-2004 02:25 AM

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

All times are GMT -5. The time now is 11:26 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