npm ошибка установки пакета установки Операция была отклонена вашей операционной системой - PullRequest
0 голосов
/ 22 января 2020

Я настраиваю тематический vuejs проект, и обычно вы просто устанавливаете пакеты и затем запускаете файл. Когда я пытаюсь установить зависимости от пакетов, я получаю эту ошибку.

admin@kali:/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin$ sudo npm install --save package.json
npm WARN deprecated package.json@2.0.1: Use pkg.json instead.
npm ERR! code EPERM
npm ERR! syscall symlink
npm ERR! path ../semver/bin/semver
npm ERR! dest /media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin/node_modules/.bin/semver
npm ERR! errno -1
npm ERR! Error: EPERM: operation not permitted, symlink '../semver/bin/semver' -> '/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin/node_modules/.bin/semver'
npm ERR!  { [Error: EPERM: operation not permitted, symlink '../semver/bin/semver' -> '/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin/node_modules/.bin/semver']
npm ERR!   cause:
npm ERR!    { Error: EPERM: operation not permitted, symlink '../semver/bin/semver' -> '/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin/node_modules/.bin/semver'
npm ERR!      errno: -1,
npm ERR!      code: 'EPERM',
npm ERR!      syscall: 'symlink',
npm ERR!      path: '../semver/bin/semver',
npm ERR!      dest:
npm ERR!       '/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin/node_modules/.bin/semver' },
npm ERR!   stack:
npm ERR!    'Error: EPERM: operation not permitted, symlink \'../semver/bin/semver\' -> \'/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin/node_modules/.bin/semver\'',
npm ERR!   errno: -1,
npm ERR!   code: 'EPERM',
npm ERR!   syscall: 'symlink',
npm ERR!   path: '../semver/bin/semver',
npm ERR!   dest:
npm ERR!    '/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin/node_modules/.bin/semver',
npm ERR!   parent: 'Admin' }
npm ERR! 
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR! 
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2020-01-22T15_05_26_096Z-debug.log

Результаты grep для узла

admin@kali:/media/veracrypt1/themeforest-LSerfC0M-skote-vuejs-admin-dashboard-template/Admin$ ps aux | grep "node"
admin       2033  6.7  1.4 1154656 218568 ?      Sl   13:38  19:01 /tmp/.mount_timedoQZlnn6/timedoctor-desktop --type=renderer --no-sandbox --service-pipe-token=527552419A327F3C50F1459F2199CAFC --lang=en-US --app-path=/tmp/.mount_timedoQZlnn6/resources/app.asar --node-integration=true --webview-tag=true --no-sandbox --native-window-open --context-id=2 --enable-pinch --num-raster-threads=2 --enable-main-frame-before-activation --content-image-texture-target=0,0,3553;0,1,3553;0,2,3553;0,3,3553;0,4,3553;0,5,3553;0,6,3553;0,7,3553;0,8,3553;0,9,3553;0,10,3553;0,11,3553;0,12,3553;0,13,3553;0,14,3553;0,15,3553;0,16,3553;0,17,3553;1,0,3553;1,1,3553;1,2,3553;1,3,3553;1,4,3553;1,5,3553;1,6,3553;1,7,3553;1,8,3553;1,9,3553;1,10,3553;1,11,3553;1,12,3553;1,13,3553;1,14,3553;1,15,3553;1,16,3553;1,17,3553;2,0,3553;2,1,3553;2,2,3553;2,3,3553;2,4,3553;2,5,3553;2,6,3553;2,7,3553;2,8,3553;2,9,3553;2,10,3553;2,11,3553;2,12,3553;2,13,3553;2,14,3553;2,15,3553;2,16,3553;2,17,3553;3,0,3553;3,1,3553;3,2,3553;3,3,3553;3,4,3553;3,5,3553;3,6,3553;3,7,3553;3,8,3553;3,9,3553;3,10,3553;3,11,3553;3,12,3553;3,13,3553;3,14,3553;3,15,3553;3,16,3553;3,17,3553;4,0,3553;4,1,3553;4,2,3553;4,3,3553;4,4,3553;4,5,3553;4,6,3553;4,7,3553;4,8,3553;4,9,3553;4,10,3553;4,11,3553;4,12,3553;4,13,3553;4,14,3553;4,15,3553;4,16,3553;4,17,3553 --disable-accelerated-video-decode --disable-gpu-compositing --enable-gpu-async-worker-context --service-request-channel-token=527552419A327F3C50F1459F2199CAFC --renderer-client-id=3 --shared-files=v8_natives_data:100,v8_snapshot_data:101
admin       2056  0.3  1.4 3132776 219372 ?      Sl   13:38   0:57 /usr/share/skypeforlinux/skypeforlinux --type=renderer --autoplay-policy=no-user-gesture-required --disable-background-timer-throttling --ms-disable-indexeddb-transaction-timeout --field-trial-handle=13768039525980348813,85520197761272456,131072 --disable-features=PictureInPicture,SpareRendererForSitePerProcess --lang=en-US --app-path=/usr/share/skypeforlinux/resources/app.asar --webview-tag --no-sandbox --no-zygote --native-window-open --preload=/usr/share/skypeforlinux/resources/app.asar/Preload.js --background-color=#fff --node-integration-in-subframes --enable-spellcheck --num-raster-threads=2 --enable-main-frame-before-activation --service-request-channel-token=16214930562191180703 --renderer-client-id=5 --no-v8-untrusted-code-mitigations --shared-files=v8_context_snapshot_data:100,v8_natives_data:101 --skype-process-type=Main --skype-window-id=__MAIN_ROOT_VIEW_ID__
admin       2585  0.0  0.7 595584 118196 ?       SLl  13:43   0:08 /usr/share/code/code --type=renderer --disable-color-correct-rendering --no-sandbox --field-trial-handle=5868520767458894563,1066928850556287455,131072 --disable-features=LayoutNG,SpareRendererForSitePerProcess --lang=en-US --standard-schemes --secure-schemes=vscode-resource --bypasscsp-schemes --cors-schemes=vscode-resource --fetch-schemes=vscode-resource --service-worker-schemes --app-path=/usr/share/code/resources/app --node-integration --no-sandbox --no-zygote --background-color=#1e1e1e --disable-blink-features=Auxclick --num-raster-threads=2 --enable-main-frame-before-activation --service-request-channel-token=8697835763661794040 --renderer-client-id=6 --no-v8-untrusted-code-mitigations --shared-files=v8_context_snapshot_data:100,v8_natives_data:101
admin       2890  0.4  0.8 944108 126300 ?       Sl   13:46   1:12 /tmp/.mount_timedoQZlnn6/timedoctor-desktop --type=renderer --no-sandbox --service-pipe-token=1154280A6248E92E0128F8A39E58D55D --lang=en-US --app-path=/tmp/.mount_timedoQZlnn6/resources/app.asar --node-integration=true --webview-tag=true --no-sandbox --context-id=2 --enable-pinch --num-raster-threads=2 --enable-main-frame-before-activation --content-image-texture-target=0,0,3553;0,1,3553;0,2,3553;0,3,3553;0,4,3553;0,5,3553;0,6,3553;0,7,3553;0,8,3553;0,9,3553;0,10,3553;0,11,3553;0,12,3553;0,13,3553;0,14,3553;0,15,3553;0,16,3553;0,17,3553;1,0,3553;1,1,3553;1,2,3553;1,3,3553;1,4,3553;1,5,3553;1,6,3553;1,7,3553;1,8,3553;1,9,3553;1,10,3553;1,11,3553;1,12,3553;1,13,3553;1,14,3553;1,15,3553;1,16,3553;1,17,3553;2,0,3553;2,1,3553;2,2,3553;2,3,3553;2,4,3553;2,5,3553;2,6,3553;2,7,3553;2,8,3553;2,9,3553;2,10,3553;2,11,3553;2,12,3553;2,13,3553;2,14,3553;2,15,3553;2,16,3553;2,17,3553;3,0,3553;3,1,3553;3,2,3553;3,3,3553;3,4,3553;3,5,3553;3,6,3553;3,7,3553;3,8,3553;3,9,3553;3,10,3553;3,11,3553;3,12,3553;3,13,3553;3,14,3553;3,15,3553;3,16,3553;3,17,3553;4,0,3553;4,1,3553;4,2,3553;4,3,3553;4,4,3553;4,5,3553;4,6,3553;4,7,3553;4,8,3553;4,9,3553;4,10,3553;4,11,3553;4,12,3553;4,13,3553;4,14,3553;4,15,3553;4,16,3553;4,17,3553 --disable-accelerated-video-decode --disable-gpu-compositing --enable-gpu-async-worker-context --service-request-channel-token=1154280A6248E92E0128F8A39E58D55D --renderer-client-id=7 --shared-files=v8_natives_data:100,v8_snapshot_data:101
root        3304  0.0  0.0   6676  2812 ?        Ss   13:51   0:12 /sbin/mount.ntfs /dev/sda4 /media/admin/662046C820469EC5 -o rw,nodev,nosuid,windows_names,uid=1001,gid=1001,uhelper=udisks2
admin       3721  4.1  1.9 895336 299168 ?       Sl   13:56  10:56 /usr/share/code/code --type=renderer --disable-color-correct-rendering --no-sandbox --field-trial-handle=5868520767458894563,1066928850556287455,131072 --disable-features=LayoutNG,SpareRendererForSitePerProcess --lang=en-US --standard-schemes --secure-schemes=vscode-resource --bypasscsp-schemes --cors-schemes=vscode-resource --fetch-schemes=vscode-resource --service-worker-schemes --app-path=/usr/share/code/resources/app --node-integration --webview-tag --no-sandbox --no-zygote --background-color=#1e1e1e --num-raster-threads=2 --enable-main-frame-before-activation --service-request-channel-token=15633612029818290602 --renderer-client-id=7 --no-v8-untrusted-code-mitigations --shared-files=v8_context_snapshot_data:100,v8_natives_data:101
admin       5001  0.0  0.5 425260 82928 ?        Sl   14:05   0:00 /usr/share/code/code --max-old-space-size=3072 /usr/share/code/resources/app/extensions/node_modules/typescript/lib/tsserver.js --syntaxOnly --useInferredProjectPerProjectRoot --disableAutomaticTypingAcquisition --cancellationPipeName /tmp/vscode-typescript1001/1a00b421f14b9cab28ff/tscancellation-538c2c3283cf4376abc6.tmp* --locale en --noGetErrOnBackgroundUpdate --validateDefaultNpmLocation
admin       5002  0.2  1.0 524044 157664 ?       Sl   14:05   0:34 /usr/share/code/code --max-old-space-size=3072 /usr/share/code/resources/app/extensions/node_modules/typescript/lib/tsserver.js --useInferredProjectPerProjectRoot --enableTelemetry --cancellationPipeName /tmp/vscode-typescript1001/1a00b421f14b9cab28ff/tscancellation-109b29d193dfb2f6ef77.tmp* --locale en --noGetErrOnBackgroundUpdate --validateDefaultNpmLocation
admin       5019  0.1  0.5 450124 78316 ?        Sl   14:05   0:26 /usr/share/code/code /usr/share/code/resources/app/extensions/node_modules/typescript/lib/typingsInstaller.js --globalTypingsCacheLocation /home/admin/.cache/typescript/3.7 --enableTelemetry --typesMapLocation /usr/share/code/resources/app/extensions/node_modules/typescript/lib/typesMap.json --validateDefaultNpmLocation
admin       5401  0.0  0.6 434872 92688 ?        Sl   14:10   0:01 /usr/share/code/code /usr/share/code/resources/app/extensions/html-language-features/server/dist/htmlServerMain --node-ipc --clientProcessId=3748
admin      11481  0.0  0.4 429948 70456 ?        Sl   15:26   0:01 /usr/share/code/code /usr/share/code/resources/app/extensions/json-language-features/server/dist/jsonServerMain --node-ipc --clientProcessId=3748
admin      11878  0.0  0.2 615608 38952 pts/2    Tl   15:28   0:01 nodejs
admin      90974  0.0  0.0   6136   900 pts/2    S+   18:22   0:00 grep node

1 Ответ

0 голосов
/ 22 января 2020

Это вопрос разрешения. Скорее всего, двоичный файл node был установлен как пользователь с другими правами доступа, чем вы думаете.

Найдите пользователя, который node работает как:

ps aux | grep "node"

Затем перейдите к этому пользователю , Теперь попытайтесь сделать такую ​​же символическую ссылку. Вы получите ту же ошибку. Отрегулируйте разрешения соответственно.

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...