AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-8481

anjanesh's questions

Martin Hope
anjanesh
Asked: 2024-06-12 02:18:26 +0800 CST

密码仅保护目录列表,而不保护文件本身

  • 9

我有/home/sammy/public_html/cache/.htaccess

Options +Indexes

<Files *>
AuthType Basic
AuthName "Authentication Required"
AuthUserFile /home/sammy/public_html/cache/.htpasswd
Require valid-user
</Files>

但我只希望目录列表受密码保护 - 而不是文件本身。

问题是,当我去时,example.test/cache/somefile.pdf它会提示输入用户名和密码。

apache2
  • 1 个回答
  • 314 Views
Martin Hope
anjanesh
Asked: 2023-04-06 12:28:14 +0800 CST

无法在 Ubuntu 22.04.1 上安装 pear

  • 5

我在 Ubuntu 22.04.1 LTS 上,返回sudo apt install php-pear:

E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/p/php8.1/php8.1-xml_8.1.2-1ubuntu2.10_amd64.deb  404  Not Found [IP: x.x.x.x 80]

这是一个 404 - http://security.ubuntu.com/ubuntu/pool/main/p/php8.1/php8.1-xml_8.1.2-1ubuntu2.10_amd64.deb

php
  • 1 个回答
  • 20 Views
Martin Hope
anjanesh
Asked: 2023-02-24 13:58:29 +0800 CST

在 Windows 11 上通过 WSL 在 Ubuntu 22.04 上安装最新的 NodeJS

  • 6

我在 Windows 11 上通过 WSL 使用 Ubuntu 22.04。

curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash -

正在返回:

## Installing the NodeSource Node.js 18.x repo...

## Populating apt-get cache...

+ apt-get update
Hit:1 https://apt.releases.hashicorp.com jammy InRelease
Hit:2 http://archive.ubuntu.com/ubuntu jammy InRelease
Get:3 http://security.ubuntu.com/ubuntu jammy-security InRelease [110 kB]
Hit:4 https://packages.redis.io/deb jammy InRelease
Get:5 http://archive.ubuntu.com/ubuntu jammy-updates InRelease [119 kB]
Get:6 http://archive.ubuntu.com/ubuntu jammy-backports InRelease [107 kB]
Reading package lists... Done
E: Release file for http://security.ubuntu.com/ubuntu/dists/jammy-security/InRelease is not valid yet (invalid for another 5h 27min 34s). Updates for this repository will not be applied.
E: Release file for http://archive.ubuntu.com/ubuntu/dists/jammy-updates/InRelease is not valid yet (invalid for another 5h 27min 59s). Updates for this repository will not be applied.
E: Release file for http://archive.ubuntu.com/ubuntu/dists/jammy-backports/InRelease is not valid yet (invalid for another 5h 28min 40s). Updates for this repository will not be applied.
Error executing command, exiting
$ sudo head /var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_jammy_InRelease
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Origin: Ubuntu
Label: Ubuntu
Suite: jammy
Version: 22.04
Codename: jammy
Date: Thu, 21 Apr 2022 17:16:08 UTC
Architectures: amd64 arm64 armhf i386 ppc64el riscv64 s390x

我是什么做的 ?

$date
Fri Feb 24 04:12:40 IST 2023
windows-subsystem-for-linux
  • 1 个回答
  • 19 Views
Martin Hope
anjanesh
Asked: 2021-02-03 04:32:52 +0800 CST

以 root 身份登录 MySQL 仅适用于 sudo

  • 0

我在 Ubuntu 20.04 上并安装了默认版本的 mysql。但是如果不使用 sudo,我似乎无法以 root 身份登录。这是对新版本的限制吗?我确信在以前版本的 Ubuntu 上不是这样的 - 14.04、12.04 等。

mysql --user=root -p
ERROR 1698 (28000): Access denied for user 'root'@'localhost'

.

sudo mysql --user=root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 80
Server version: 8.0.22-0ubuntu0.20.04.3 (Ubuntu)
mysql
  • 1 个回答
  • 2340 Views
Martin Hope
anjanesh
Asked: 2021-02-01 04:52:40 +0800 CST

pandas 0.24.2 没有安装在没有 sudo 的虚拟环境中

  • 2
cat requirements.txt 
requests==2.22.0
pandas==0.24.2

我遇到了很多错误。这是权限问题。
当我这样做sudo pip3 install -r requirements.txt时,没有错误并且成功安装了 pandas-0.24.2。我在 Ubuntu 20.04.1 上。
在虚拟环境中,所有包都下载到/home/ubuntu/.virtualenvs/my-project/lib/python3.8/site-packages,那么为什么需要 sudo ?

virtualenvwrapper
  • 1 个回答
  • 436 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve