<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
	<channel>
		<title><![CDATA[Latest posts for the topic "如何刪除hard link檔案"]]></title>
		<link>https://forum.andowson.com/posts/list/16.page</link>
		<description><![CDATA[Latest messages posted in the topic "如何刪除hard link檔案"]]></description>
		<generator>JForum - http://www.jforum.net</generator>
			<item>
				<title>如何刪除hard link檔案</title>
				<description><![CDATA[ 今天在某部主機上發現在/etc底下多了一個~檔案，指向/root，想將其刪除的話需特別小心，因為這是個hard link，且又連到/root目錄，不能直接rm -rf ~，這樣子會把/root一併刪掉。查了一下網路上的資料，發現照下面的作法就可以順利完成了： 
<br>
在/etc目錄底下找出該hard link檔案的inode號碼 
<br>
[code]ls -i[/code] 
<br>
<br>
然後用下列指令來刪除 
<br>
[code]find -inum inode號碼 -exec rm {} \;[/code] 
<br>
<br>
參考資料: 
<br>
http://www.linuxsir.org/bbs/showthread.php?t=283141]]></description>
				<guid isPermaLink="true">https://forum.andowson.com/posts/preList/455/925.page</guid>
				<link>https://forum.andowson.com/posts/preList/455/925.page</link>
				<pubDate><![CDATA[Wed, 3 Nov 2010 18:22:55]]> GMT</pubDate>
				<author><![CDATA[ andowson]]></author>
			</item>
	</channel>
</rss>