小编Fil*_*Fil的帖子

尚未使用systemd作为初始化系统(PID 1)引导系统。无法操作

我正在尝试按照WSL中有关数字海洋的本文中的讨论进行Redis安装过程。安装的Ubuntu版本是Ubuntu 18.04。

Redis安装中的一切都很好,但是当我尝试运行此命令时sudo systemctl start redis,收到了此消息。

System has not been booted with systemd as init system (PID 1). Can't operate.
Run Code Online (Sandbox Code Playgroud)

关于该怎么办的任何想法?

redis windows-subsystem-for-linux ubuntu-18.04

34
推荐指数
7
解决办法
7万
查看次数

git pull时错误无法统计

我尝试使用以下命令从远程分支执行git pull:

$ git pull origin branch_name
username@private_repository's password:
From ssh://private_repository/path/project
 * tag               branch_name       -> FETCH_HEAD
error: cannot stat 'path/name/of/file': Permission denied
error: cannot stat 'path/name/of/file': Permission denied
Run Code Online (Sandbox Code Playgroud)

但是我收到以下错误:

error: cannot stat 'path/name/of/file': Permission denied 
error: cannot stat 'path/name/of/file': Permission denied
Run Code Online (Sandbox Code Playgroud)

有谁知道这意味着什么,我能做些什么呢?

谢谢

git permissions file

28
推荐指数
6
解决办法
3万
查看次数

sh:1:node:权限被拒绝

试图在ubuntu 18.04上运行此命令

npm install -g pngquant-bin
Run Code Online (Sandbox Code Playgroud)

但我得到了这个错误,

[..................] | fetchMetadata: sill resolveWithNewModule npm-conf@1.1.3 checking installable status
npm WARN deprecated gulp-util@3.0.8: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5
/root/.nvm/versions/node/v10.8.0/bin/pngquant -> /root/.nvm/versions/node/v10.8.0/lib/node_modules/pngquant-bin/cli.js

> pngquant-bin@5.0.0 postinstall /root/.nvm/versions/node/v10.8.0/lib/node_modules/pngquant-bin
> node lib/install.js

sh: 1: node: Permission denied
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! pngquant-bin@5.0.0 postinstall: `node lib/install.js`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the pngquant-bin@5.0.0 …
Run Code Online (Sandbox Code Playgroud)

node.js npm

17
推荐指数
6
解决办法
9970
查看次数

要加载 ES 模块,请在 package.json 中设置 "type": "module" 或使用 .mjs 扩展名

我试图在桌面上运行这个存储库一个 vscode 扩展。

我在本地克隆它并运行 npm install

在 vscode 编辑器上按 f5 并出现错误

Process exited with code 1
(node:1404) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.
(Use `node --trace-warnings ...` to show where the warning was created)
internal/process/warning:44
Canceled
Run Code Online (Sandbox Code Playgroud)

为了解决这个警告,我发现了另一个 stackoverflow 问题 - (node:9374) 警告:要加载 ES 模块,请设置 "type": "module"

所以我设置"type":"module"package.json,然后按F5一次。

并出现另一个错误。

Process exited with code 1
Uncaught TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts" for /mnt/c/vscode-php-debug/src/phpDebug.ts
Run Code Online (Sandbox Code Playgroud)

并在 …

node.js typescript visual-studio-code

14
推荐指数
4
解决办法
7235
查看次数

Xdebug: [Step Debug] 无法连接到调试客户端。试过: localhost:9003(通过 xdebug.client_host/xdebug.client_port 回退):-(

xdebug ang php 的此消息的解决方法是什么?

Xdebug: [Step Debug] Could not connect to debugging client. Tried: localhost:9003 (fallback through xdebug.client_host/xdebug.client_port) :-(
Run Code Online (Sandbox Code Playgroud)

当我composer updateWSL2安装时运行时显示此消息UBUNTU 20.01

我当前的 php 版本是 php8xdebug3

更新:

这是 x-debug 部分

xdebug

__   __   _      _
\ \ / /  | |    | |
 \ V / __| | ___| |__  _   _  __ _
  > < / _` |/ _ \ '_ \| | | |/ _` |
 / . \ (_| …
Run Code Online (Sandbox Code Playgroud)

php wsl-2 ubuntu-20.04 xdebug-3

14
推荐指数
1
解决办法
7779
查看次数

警告:/etc/php/7.2/mods-available下不存在模块mcrypt ini文件

我一直在尝试在安装了灯的Ubuntu 16.04.3 LTS中安装phpmyadmin,php 7.2,mysql Ver 15.1 Distrib 10.2.12-MariaDB,用于使用readline 5.2和apache2的debian-linux-gnu(x86_64).

我正在关注digitalOcean的这篇文章,但是当我来到我需要运行的部分时,sudo phpenmod mcrypt我得到了一条消息说...

警告:/etc/php/7.2/mods-available下不存在模块mcrypt ini文件

我在godaddy上安装的ubuntu上这样做

你能为此提供最佳解决方案吗?

php mysql lamp server ubuntu-16.04

13
推荐指数
1
解决办法
3万
查看次数

Watchpack 错误(初始扫描):错误:EACCES:权限被拒绝,lstat '/mnt/c/DumpStack.log.tmp'

npm run watch在 WSL2 (Ubuntu 20.04.1 LTS) 上运行。但出现以下错误。

Watchpack Error (initial scan): Error: EACCES: permission denied, lstat '/mnt/c/DumpStack.log.tmp'
Watchpack Error (initial scan): Error: EACCES: permission denied, lstat '/mnt/c/hiberfil.sys'
Watchpack Error (initial scan): Error: EACCES: permission denied, lstat '/mnt/c/pagefile.sys'
Watchpack Error (initial scan): Error: EACCES: permission denied, lstat '/mnt/c/swapfile.sys'
Run Code Online (Sandbox Code Playgroud)

这是我的 webpack 配置

const path = require('path');
const devMode = process.env.NODE_ENV !== 'production';
const MiniCssExtractPlugin = require('mini-css-extract-plugin');

module.exports = {
    entry: {
        "main": './views/js/main.js'
    },
    mode: 'development',
    output: {
        filename: …
Run Code Online (Sandbox Code Playgroud)

webpack

10
推荐指数
1
解决办法
1万
查看次数

字符 14 处公共模式的权限被拒绝

我正在使用 postgresql 15

我尝试运行这些

grant all privileges on database my_database to my_database_user;
grant all privileges on all tables in schema public to my_database_user;
grant all privileges on all sequences in schema public to my_database_user;
grant all privileges on all functions in schema public to my_database_user;
Run Code Online (Sandbox Code Playgroud)

但当我跑步时

php artisan 迁移 --seed

我有

SQLSTATE[42501]:权限不足:7 错误:字符 14 处的架构公共权限被拒绝(SQL:创建表“迁移”(“id”序列主键不为空,“迁移”varchar(255)不为空,“批处理”)整数不为空))

我缺少什么?

我确实确保 .env 具有正确的凭据

DB_CONNECTION=pgsql
DB_HOST=127.0.0.1
DB_PORT=5432
DB_DATABASE=my_database
DB_USERNAME=my_database_user
DB_PASSWORD=password
Run Code Online (Sandbox Code Playgroud)

检查我是否做到了

postgres=# \du my_database_user
            List of roles
  Role name  | Attributes | Member of 
-------------+------------+----------- …
Run Code Online (Sandbox Code Playgroud)

postgresql laravel-9

9
推荐指数
1
解决办法
1万
查看次数

PHP 警告:PHP 启动:无法加载动态库“mcrypt.so”

我正在尝试在 ubuntu 06.04 上使用 composer update 更新 laravel,但每次运行时composer update总是出现此警告。

PHP Warning:  PHP Startup: Unable to load dynamic library 'mcrypt.so' (tried: /usr/lib/php/20170718/mcrypt.so (/usr/lib/php/20170718/mcrypt.so: cannot open shared object file: No such file or directory), /usr/lib/php/20170718/mcrypt.so.so (/usr/lib/php/20170718/mcrypt.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Run Code Online (Sandbox Code Playgroud)

有谁知道怎么处理?

我正在使用 php7.2

php server ubuntu-16.04

8
推荐指数
2
解决办法
3万
查看次数

invoke-rc.d:无法确定当前运行级别

WSL安装mysql出现这样的问题是什么?

invoke-rc.d: could not determine current runlevel
 * Stopping MySQL database server mysqld                                                                                                                                                                                              [ OK ]
/var/lib/dpkg/info/mysql-server-5.7.postinst: line 191: /usr/share/mysql-common/configure-symlinks: No such file or directory
dpkg: error processing package mysql-server-5.7 (--configure):
 installed mysql-server-5.7 package post-installation script subprocess returned error exit status 127
dpkg: dependency problems prevent configuration of mysql-server:
 mysql-server depends on mysql-server-5.7; however:
  Package mysql-server-5.7 is not configured yet.

dpkg: error processing package mysql-server (--configure):
 dependency problems - leaving unconfigured
dmesg: read kernel buffer failed: Function not implemented
                                                          No …
Run Code Online (Sandbox Code Playgroud)

mysql windows-subsystem-for-linux

7
推荐指数
1
解决办法
1万
查看次数