亚洲av成人无遮挡网站在线观看,少妇性bbb搡bbb爽爽爽,亚洲av日韩精品久久久久久,兔费看少妇性l交大片免费,无码少妇一区二区三区

  免費(fèi)注冊 查看新帖 |

Chinaunix

  平臺 論壇 博客 文庫
最近訪問板塊 發(fā)新帖
查看: 5636 | 回復(fù): 8
打印 上一主題 下一主題

Solaris10下無法刪除目錄 [復(fù)制鏈接]

論壇徽章:
0
跳轉(zhuǎn)到指定樓層
1 [收藏(0)] [報告]
發(fā)表于 2014-03-04 15:57 |只看該作者 |倒序?yàn)g覽
環(huán)境信息:Solaris 10u10
內(nèi)核版本:Generic_150400-03
問題現(xiàn)象:
無法用rm命令刪除abc目錄,ls -al查看發(fā)現(xiàn)是空目錄,但是硬鏈接數(shù)不對,正常的空目錄是2,abc目錄顯示是3.
請問下有什么辦法來糾正硬鏈接數(shù)不對這個問題呢,從而可以正常刪除該目錄?
# ls -al abc/
total 32
drwxr-x---   3 root     root         117 Mar  4 10:33 .
drwxrwxrwt   5 root     sys          559 Mar  4 11:44 ..
# rm -rf abc/
rm: Unable to remove directory abc/: File exists

論壇徽章:
33
榮譽(yù)會員
日期:2011-11-23 16:44:17天秤座
日期:2014-08-26 16:18:20天秤座
日期:2014-08-29 10:12:18丑牛
日期:2014-08-29 16:06:45丑牛
日期:2014-09-03 10:28:58射手座
日期:2014-09-03 16:01:17寅虎
日期:2014-09-11 14:24:21天蝎座
日期:2014-09-17 08:33:55IT運(yùn)維版塊每日發(fā)帖之星
日期:2016-04-17 06:23:27操作系統(tǒng)版塊每日發(fā)帖之星
日期:2016-04-18 06:20:00IT運(yùn)維版塊每日發(fā)帖之星
日期:2016-04-24 06:20:0015-16賽季CBA聯(lián)賽之天津
日期:2016-05-06 12:46:59
2 [報告]
發(fā)表于 2014-03-04 16:42 |只看該作者
ls -ald abc

論壇徽章:
0
3 [報告]
發(fā)表于 2014-03-04 19:57 |只看該作者
本帖最后由 San風(fēng)夕 于 2014-03-04 19:58 編輯

# ls -ald abc
drwxr-x---   3 root     root         117 Mar  4 10:33 abc
回復(fù) 2# q1208c


   

論壇徽章:
2
雙魚座
日期:2014-02-23 12:10:03操作系統(tǒng)版塊每日發(fā)帖之星
日期:2015-12-17 06:20:00
4 [報告]
發(fā)表于 2014-03-04 22:02 |只看該作者
rmdir?????

論壇徽章:
33
榮譽(yù)會員
日期:2011-11-23 16:44:17天秤座
日期:2014-08-26 16:18:20天秤座
日期:2014-08-29 10:12:18丑牛
日期:2014-08-29 16:06:45丑牛
日期:2014-09-03 10:28:58射手座
日期:2014-09-03 16:01:17寅虎
日期:2014-09-11 14:24:21天蝎座
日期:2014-09-17 08:33:55IT運(yùn)維版塊每日發(fā)帖之星
日期:2016-04-17 06:23:27操作系統(tǒng)版塊每日發(fā)帖之星
日期:2016-04-18 06:20:00IT運(yùn)維版塊每日發(fā)帖之星
日期:2016-04-24 06:20:0015-16賽季CBA聯(lián)賽之天津
日期:2016-05-06 12:46:59
5 [報告]
發(fā)表于 2014-03-05 07:49 |只看該作者
回復(fù) 3# San風(fēng)夕

這就不知道了. ls顯示, 這是一個標(biāo)準(zhǔn)的目錄, 也沒有 acl 設(shè)置.


   

論壇徽章:
0
6 [報告]
發(fā)表于 2014-03-05 11:26 |只看該作者
本帖最后由 San風(fēng)夕 于 2014-03-05 11:27 編輯

# rmdir abc/
rmdir: directory "abc/": Directory not empty
# ls -al abc/
total 32
drwxr-x---   3 root     root         117 Mar  4 10:33 .
drwxrwxrwt   5 root     sys          559 Mar  5 03:30 ..
# rm -rf abc/
rm: Unable to remove directory abc/: File exists
這個目錄下肯定是丟失了目錄什么的吧,現(xiàn)在的表現(xiàn)就是:1.硬鏈接數(shù)不對(我標(biāo)紅的那里,本來空目錄應(yīng)該是2的.) 2.無法刪除.
回復(fù) 4# 東方蜘蛛


   

論壇徽章:
0
7 [報告]
發(fā)表于 2014-03-06 05:13 |只看該作者
Kernel 150400 有嚴(yán)重Bugs, 請更新到150400-09再試試.

論壇徽章:
0
8 [報告]
發(fā)表于 2014-03-18 18:20 |只看該作者
給你看看網(wǎng)上查到的
https://blogs.oracle.com/paulie/ ... rectory_file_exists

Cannot remove directory: File exists
By paulie on May 20, 2009
If you try to delete a directory over NFS and get an error such as...

rm: cannot remove directory `asdf/': File exists

... you will notice that conventional methods won't be good enough to remove it.

$ chmod -R 777 asdf/
$ rm -rf asdf/
$ rm: cannot remove directory `asdf/': File exists

Usually there is a file like .nfs234B inside the directory than can be displayed with ls -la

$ ls -la
total 146
drwxr-xr-x 2 user group    512 2009-05-20 08:51 .
drwxr-xr-x 3 user group    512 2009-05-19 08:59 ..
-rwxr-xr-x 1 user group 134888 2009-05-18 12:45 .nfs234B

Removing this file only replaces it with another. There are two solutions: manually delete the file on the NFS server, or (if you don't have that type of access) kill its process.

$fuser -u asdf/.\*
asdf/.:     9070c(user)
asdf/..:    28690c(user)   24845c(user)
asdf/.nfs934B:     9070tm(user)

9070 is the offending process. Kill it with fire.

$ kill -9 9070

Should be able to remove that directory now.

論壇徽章:
0
9 [報告]
發(fā)表于 2014-03-20 12:50 |只看該作者
先謝謝了,
我這里的情況跟你找到的還不一樣,最終確認(rèn)可能的原因是在目錄下使用了unlink命令刪了一個文件,導(dǎo)致該目錄的硬鏈接數(shù)不對,無法刪除.
回復(fù) 8# calcm


   
您需要登錄后才可以回帖 登錄 | 注冊

本版積分規(guī)則 發(fā)表回復(fù)

  

北京盛拓優(yōu)訊信息技術(shù)有限公司. 版權(quán)所有 京ICP備16024965號-6 北京市公安局海淀分局網(wǎng)監(jiān)中心備案編號:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年舉報專區(qū)
中國互聯(lián)網(wǎng)協(xié)會會員  聯(lián)系我們:huangweiwei@itpub.net
感謝所有關(guān)心和支持過ChinaUnix的朋友們 轉(zhuǎn)載本站內(nèi)容請注明原作者名及出處

清除 Cookies - ChinaUnix - Archiver - WAP - TOP