window下cygwin完全解除安裝辦法【轉】

東北胖子發表於2013-06-14

具體步驟如下:

1.刪除安裝用的臨時資料夾(在cygwin裡輸入命令)

$ rm -f /cygdrive/c/你的臨時資料夾

2.停止cron service

$ cygrunsrv --stop cron

$ cygrunsrv --remove cron

3.停止並刪除inetd服務

$ net stop inetd

$/usr/sbin/inetd --remove-as-service

4.刪除安裝資料夾,預設是c:/cygwin

5.刪除桌面上的icon,和開始選單裡的啟動資料夾

6.刪除登錄檔裡的相關項

HKEY_LOCAL_MACHINE/SOFTWARE/Cygnus Solutions

HKEY_CURRENT_USER/Software/Cygnus Solutions

7.刪除環境變數(PATH, CYGWIN)

環境變數PATH裡的c:/cygwin/bin; 還有名叫CYGWIN的變數

 

 

 

==================cygwin官方的分割線==================

 

 

 

Cygwin目錄及檔案的刪除(2007-10-19 00:13:48)

今天整理下硬碟裡亂七八糟的東西,太亂太多不好整理,刪除一些東西。看到以前儲存的網頁才想到有個問題還沒解決——還沒把cygwin刪掉。這個cygwin目錄還是幾年前裝的,XP重灌N次了,小天鵝也重灌過幾次,都用同一個目錄。

原文章在,一樣的問題:

Hi,
    I installed cygwin a few months ago(installed on XP). I reinstalled WindowsXP recently. But there are some files in cygwin installation
directory can be deleted. Could somebody help me?
Best wishes,
Peng

cygwin的Larry Hall給出了:

  Presumably, you reinstalled XP but left the previously
installed Cygwin intact. 

  So now it's possible you have files that were installed via Cygwin originally with a user/uid that doesn't exist on your Windows system anymore.
  A "Cygwin" way to resolve this would be to 'chown' of all
your files to a uid that exists for your new installation.
You should be able to manipulate the files as that user.
  Alternatively, you could change the uid (not your SID!) of
your user in your /etc/passwd file to correspond with your
old uid. 

  Finally, you could take ownership of the Cygwin
tree using the Windows security property tab.  I expect
you could find other ways to solve this problem too. ;-)

 

也看了別人的文章

一般故障表現:
以使用者X登陸機器並安裝了cygwin後,使用者Y或者域使用者Z登陸該機器後無法刪除cygwin及其子目錄檔案。
解決辦法:
1。原安裝使用者不是管理員使用者,可以以原安裝使用者登陸將需要做刪除操作的使用者加入完全訪問許可權或者加入所有者列表。
2。以系統管理員登陸將需要做刪除操作的使用者加入所有者列表。

 

  問題解決了。

 

 這個問題告訴我們,不管你遇到什麼問題(困難),肯定有人在你之前就遇到過了,肯定就有解決的辦法,因此要正視困難,並解決之。

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/2317695/viewspace-763907/,如需轉載,請註明出處,否則將追究法律責任。

相關文章