
서버 운영 체제를 업데이트하는 데 문제가 있습니다. 실행할 때 발생하는 오류 목록은 다음과 같습니다 sudo yum update
.
file /usr/lib/node_modules/npm/node_modules/which/package.json from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-which-1.0.5-8.el6.noarch
file /usr/lib/node_modules/npm/node_modules/which/bin/which from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-which-1.0.5-8.el6.noarch
file /usr/lib/node_modules/npm/node_modules/which/which.js from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-which-1.0.5-8.el6.noarch
file /usr/lib/node_modules/npm/node_modules/uid-number/package.json from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-uid-number-0.0.3-7.el6.noarch
file /usr/lib/node_modules/npm/node_modules/uid-number/get-uid-gid.js from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-uid-number-0.0.3-7.el6.noarch
file /usr/lib/node_modules/npm/node_modules/uid-number/uid-number.js from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-uid-number-0.0.3-7.el6.noarch
file /usr/lib/node_modules/npm/node_modules/osenv/package.json from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-osenv-0.0.3-5.el6.noarch
file /usr/lib/node_modules/npm/node_modules/osenv/osenv.js from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package nodejs-osenv-0.0.3-5.el6.noarch
file /usr/lib/node_modules/npm/bin/npm from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package npm-1.3.6-5.el6.noarch
file /usr/lib/node_modules/npm/bin/node-gyp-bin/node-gyp from install of nodejs-2:8.17.0-1nodesource.x86_64 conflicts with file from package npm-1.3.6-5.el6.noarch
file /usr/lib/node_modules/npm/node_modules/node-gyp from install of nodejs-
목록이 더 깁니다!
답변1
부분 목록에서 볼 수 있듯이, 설치한 버전 nodejs
( 릴리스 문자열) 8.17.0
이 시스템 저장소에서 제공하는 버전(릴리스 문자열)과 nodesource
충돌합니다 . el6
이제 업데이트할 때 일부 시스템 잔재가 업데이트를 시도하거나 시스템 저장소가 설치된 패키지를 업데이트하기 위해 버전 요구 사항을 충족하는 업데이트를 제공하지만 패키지 방식이나 다른 버전으로 인해 충돌이 발생합니다. 시스템 패키지 종속성.
그것가능한yum
업데이트를 건너뛰도록 지시하기에 충분합니다 npm
(이는 표시되는 출력 목록에서 적어도 하나의 명백한 충돌이고 아마도 다른 충돌하는 업데이트를 도입할 책임이 있기 때문입니다)
sudo yum update --exclude=npm
최신 버전만 유지하려면 nodejs
시스템 저장소에서 nodejs
/ 패키지의 모든 추적을 찾아서( 패키지 릴리스 문자열에 npm
있을 수 있음 ) 최신 버전이 유지되도록 사용해야 합니다.el6
yum remove
오직남은 버전. 그러나 이 작업을 수행할 때 이전 버전이 필요한 다른 패키지를 찾을 수 있으므로 시스템에 대한 잠재적인 영향을 고려하지 않고 이를 강제해서는 안 됩니다.