zowe / zowe-cli-db2-plugin

DB2 Plugin for the Zowe CLI
Eclipse Public License 2.0
8 stars 16 forks source link

Unable to uninstall DB2 from Zowe #6

Open JTonda opened 5 years ago

JTonda commented 5 years ago

From @AHumanFromCA on September 26, 2018 14:20

Opened this issue a while ago, I am transferring it over here since I do not see that it has been resolved yet.


I am unable to uninstall the DB2 plugin through Brightside.

The first uninstall attempt reports back that there is a locked file:

$ bright plugins uninstall @brightside/db2
npm ERR! path C:\Users\XXXXXXXX\.brightside\plugins\installed\node_modules\@brightside\db2\node_modules\ibm_db\installer\clidriver\bin\amd64.VC11.CRT
npm ERR! code EBUSY
npm ERR! errno -4082
npm ERR! syscall rmdir
npm ERR! EBUSY: resource busy or locked, rmdir 'C:\Users\XXXXXXXX\.brightside\plugins\installed\node_modules\@brightside\db2\node_modules\ibm_db\installer\clidriver\bin\amd64.VC11.CRT'

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\XXXXXXXX\AppData\Roaming\npm-cache\_logs\2018-07-30T21_24_21_271Z-debug.log
Command Error:
Uninstall Failed
Error Details:
Command failed: npm uninstall "@brightside/db2" --prefix C:\Users\XXXXXXXX\.brightside\plugins\installed -g

Sometimes this will break npm cache and make DB2 uninstallable without a complete reinstall.

My theory is that the lock somehow is gathered by the bright process due to these observations.

That 2nd observation is why I believe that it isn't because of antivirus software.

App Version
Brightside 1.0.1
npm 6.0.0
Node 10.6.0
DB2 1.0.0

Copied from original issue: gizafoundation/zowe-cli-db2-plugin#4

zFernand0 commented 1 year ago

Cannot reproduce the issue with the newer versions of the package

t1m0thyj commented 1 year ago

I'm seeing this error again:

$ zowe plugins uninstall @zowe/db2-for-zowe-cli
npm ERR! code EBUSY
npm ERR! syscall rename
npm ERR! path C:\Users\Timothy\.zowe\plugins\installed\node_modules\@zowe\db2-for-zowe-cli\node_modules\ibm_db\installer\clidriver\bin
npm ERR! dest C:\Users\Timothy\.zowe\plugins\installed\node_modules\@zowe\.db2-for-zowe-cli-6tqjQbu5\node_modules\ibm_db\installer\clidriver\bin
npm ERR! errno -4082
npm ERR! EBUSY: resource busy or locked, rename 'C:\Users\Timothy\.zowe\plugins\installed\node_modules\@zowe\db2-for-zowe-cli\node_modules\ibm_db\installer\clidriver\bin' -> 'C:\Users\Timothy\.zowe\plugins\installed\node_modules\@zowe\.db2-for-zowe-cli-6tqjQbu5\node_modules\ibm_db\installer\clidriver\bin'

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Timothy\AppData\Local\npm-cache\_logs\2023-06-16T14_50_20_813Z-debug-0.log
Command Error:
Uninstall Failed
Error Details:
Command failed: C:\Program Files\nodejs\npm.CMD uninstall @zowe/db2-for-zowe-cli --prefix C:\Users\Timothy\.zowe\plugins\installed -g
App Version
Zowe CLI 7.16.2
npm 9.5.1
Node 18.16.0
DB2 plug-in 5.0.3