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-694357

yukashima huksay's questions

Martin Hope
yukashima huksay
Asked: 2018-02-09 01:18:05 +0800 CST

wget 卡在镜像网页的中间

  • 0

我正在使用以下命令镜像一个网站:

wget -m -nc -p -E -k -np -e robots=off https://www.somesite.com/ & disown

一切都很好,直到我看到它卡在了

Reusing existing connection to www.somesite.com:443.

我关闭了那个tty。

我应该怎么做才能让它继续?

这是 wget 输出的一部分:

www.somesite.com/.../sport.html       [   <=>                                           ] 833.32K  1.53MB/s    in 0.5s    
Last-modified header missing -- time-stamps turned off.
2018-02-10 16:34:23 (1.53 MB/s) - ‘www.somesite.com/.../sport.html’ saved [853319]

--2018-02-10 16:34:23--  http://www.somesite.com/.../social
Reusing existing connection to www.somesite.com:80.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: ‘www.somesite.com/.../social.html’

www.somesite.com/.../social.html      [ <=>                                             ] 141.35K   816KB/s    in 0.2s    

Last-modified header missing -- time-stamps turned off.
2018-02-10 16:34:24 (816 KB/s) - ‘www.somesite.com/.../social.html’ saved [144747]

--2018-02-10 16:34:24--  http://www.somesite.com/.../parliament
Reusing existing connection to www.somesite.com:80.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: ‘www.somesite.com/.../parliament.html’

我使用的命令是:

wget -m -c -p -E -k -np -e robots=off https://www.somesite.com

有没有办法指示 wget 不下载它之前已经下载的相同 url?

wget downloads
  • 1 个回答
  • 3287 Views
Martin Hope
yukashima huksay
Asked: 2018-02-06 02:21:55 +0800 CST

如何将目录中的所有图像转换为 jpg?

  • 2

我在一个目录中有很多不同的图像,它们的名称1 2 3 4 ...是连续的,我想知道是否可以在jpg不保留纵横比的情况下将它们全部转换为 900x900 并将它们全部调整为 900x900。

我在第一部分尝试的是:

$ mogrify -format jpg -- *

但是当我这样做时,内存使用量增加得如此之快,然后进程就被杀死了。 我尝试调整大小的是:

$ mogrify -resize 900x900 -- *
mogrify: insufficient image data in file `109.jpg' @ error/jpeg.c/ReadJPEGImage/1039.
mogrify: no decode delegate for this image format `' @ error/constitute.c/ReadImage/501.
mogrify: no decode delegate for this image format `' @ error/constitute.c/ReadImage/501.
mogrify: no decode delegate for this image format `' @ error/constitute.c/ReadImage/501.
mogrify: no decode delegate for this image format `' @ error/constitute.c/ReadImage/501.

正如我所说,文件的名称是序号。我还有以下内容:

$ file * | grep -Po "^\d*: *\K[^:,]*(?=,)" | sort | uniq
ASCII text
GIF image data
JPEG image data
PNG image data

那么问题是什么?我该如何解决?

resize image-processing imagemagick mogrify
  • 1 个回答
  • 5003 Views
Martin Hope
yukashima huksay
Asked: 2018-01-05 10:42:19 +0800 CST

如何使用 read -ra inline?

  • 2

我需要从 python 运行命令,所以我正在做:

os.system('IFS=".";for f in data/* ; do read -ra ADDR <<< "$f";     mv "$f" "data/${ADDR[-1]}"; done;')

但它说:

sh: 1: Syntax error: redirection unexpected

但如果我在 bash 中运行它,它工作正常:

IFS="."
for f in data/* 
do 
    read -ra ADDR <<< "$f"
    mv "$f" "data/${ADDR[-1]}"
done;

它工作得很好。如何修复它以使其在一条线上工作?

bash
  • 2 个回答
  • 1434 Views
Martin Hope
yukashima huksay
Asked: 2018-01-05 03:12:06 +0800 CST

如何仅解压缩 zip 存档的前几行?

  • 6

我有一个压缩文本文件a.zip,我想阅读它的前 10 行。是否可以在不解压缩整个文件的情况下做到这一点?

zip
  • 1 个回答
  • 7271 Views
Martin Hope
yukashima huksay
Asked: 2017-12-28 04:37:52 +0800 CST

删除python后如何修复未满足的依赖项?

  • 0

我为安装应用程序而苦苦挣扎。在评论中的某个地方,有人说我变得残忍并且做了rm -rf /usr/lib/python2.7,然后我也做了同样的事情。在那之后我sudo apt purge python2.7-minimal现在我的系统完全崩溃了,例如当sudo apt upgrade我得到:

The following packages have unmet dependencies:
 gimp : Depends: python:any (>= 2.6.6-7~)
 libboost-mpi-python1.58.0 : Depends: python (< 2.8) but it is not installed
                             Depends: python (>= 2.7~) but it is not installed
                             Depends: python:any (>= 2.7.5-5~)
 libboost-python1.58-dev : Depends: python-dev but it is not installed
                           Depends: python:any (< 2.8)
                           Depends: python:any (>= 2.7.5-5~)
                           Depends: python (>= 2.5) but it is not installed or
                                    python-celementtree but it is not installable or
                                    python-elementtree but it is not installable
 ndiff : Depends: python:any (< 2.8)
         Depends: python:any (>= 2.7.5-5~)
 python-bs4 : Depends: python:any (< 2.8)
              Depends: python:any (>= 2.7.5-5~)
 python-cairo : Depends: python (< 2.8) but it is not installed
                Depends: python (>= 2.7~) but it is not installed
                Depends: python:any (>= 2.7.5-5~)
 python-chardet : Depends: python:any (< 2.8)
                  Depends: python:any (>= 2.7.5-5~)
                  Depends: python-pkg-resources but it is not installed
 python-dbus : Depends: python (< 2.8) but it is not installed
               Depends: python (>= 2.7~) but it is not installed
               Depends: python:any (>= 2.7.5-5~)
 python-gi : Depends: python (< 2.8) but it is not installed
             Depends: python (>= 2.7~) but it is not installed
             Depends: python:any (>= 2.7.5-5~)
 python-gobject-2 : Depends: python (< 2.8) but it is not installed
                    Depends: python (>= 2.7~) but it is not installed
                    Depends: python:any (>= 2.7.5-5~)
 python-gtk2 : Depends: python (>= 2.7) but it is not installed
               Depends: python (< 2.8) but it is not installed
 python-html5lib : Depends: python-six but it is not installed
                   Depends: python:any (< 2.8)
                   Depends: python:any (>= 2.7.5-5~)
 python-lxml : Depends: python (>= 2.7) but it is not installed
               Depends: python (< 2.8) but it is not installed
 python-pip : Depends: python:any (< 2.8)
              Depends: python:any (>= 2.7.5-5~)
              Recommends: python-all-dev (>= 2.6) but it is not installed
 python-setuptools : Depends: python-pkg-resources (= 20.7.0-1) but it is not installed
                     Depends: python:any (< 2.8)
                     Depends: python:any (>= 2.7.5-5~)
 python-wheel : Depends: python:any (< 2.8)
                Depends: python:any (>= 2.7.5-5~)
 python-xlib : Depends: python:any (< 2.8)
               Depends: python:any (>= 2.7.5-5~)
 speedtest-cli : Depends: python (>= 2.7) but it is not installed
                 Depends: python (< 2.8) but it is not installed
                 Depends: python-pkg-resources but it is not installed

当我发布时,sudo apt-get -f install我得到:

The following additional packages will be installed:
  python python-dev python-pkg-resources python-six python2.7-dev
Suggested packages:
  python-doc python-tk
The following NEW packages will be installed:
  python python-dev python-pkg-resources python-six python2.7-dev
0 upgraded, 5 newly installed, 0 to remove and 0 not upgraded.
21 not fully installed or removed.
Need to get 0 B/533 kB of archives.
After this operation, 1,465 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Setting up python2.7-minimal (2.7.12-1ubuntu0~16.04.2) ...
Could not find platform independent libraries <prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
python2.7: can't open file '/usr/lib/python2.7/py_compile.py': [Errno 2] No such file or directory
dpkg: error processing package python2.7-minimal (--configure):
 subprocess installed post-installation script returned error exit status 2
dpkg: dependency problems prevent configuration of python-minimal:
 python-minimal depends on python2.7-minimal (>= 2.7.11-1~); however:
  Package python2.7-minimal is not configured yet.

dpkg: error processing package python-minimal (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
                                                                                                          Errors were encountered while processing:
 python2.7-minimal
 python-minimal
E: Sub-process /usr/bin/dpkg returned an error code (1)

我现在该怎么办!?我怎样才能修复我毁了的东西!?

16.04
  • 2 个回答
  • 9220 Views
Martin Hope
yukashima huksay
Asked: 2017-12-19 00:17:35 +0800 CST

如何将换行符分隔的列表作为参数传递给另一个命令?

  • 15

所以我有一个用户名列表,例如:

user1
user2
user3

我想申请id他们每个人并得到类似的东西:

uid=100(user1) gid=5(g1) groups=5(g1),6(g6),7(g10)
.
.

我怎样才能做到这一点?请注意,该列表是另一个命令 say 的输出mycommand。

command-line
  • 3 个回答
  • 12361 Views
Martin Hope
yukashima huksay
Asked: 2017-12-18 21:29:13 +0800 CST

如何检查哪些应用程序可以访问我的剪贴板?

  • 2

我想知道某些应用程序是否可以读取我的剪贴板的内容以及将密码复制到剪贴板的安全风险。如何检查哪些进程可以访问我的剪贴板(读/写)?

security
  • 1 个回答
  • 489 Views
Martin Hope
yukashima huksay
Asked: 2017-12-11 06:23:00 +0800 CST

如何获取我已阅读权限的文件的目录树

  • 1

我想获取我拥有读取权限的服务器中所有文件的目录树。我怎样才能做到这一点!?

permissions
  • 1 个回答
  • 130 Views
Martin Hope
yukashima huksay
Asked: 2017-12-11 02:12:50 +0800 CST

如何获取可以通过 ssh 访问服务器的所有用户的列表?

  • 21

如何获取可以通过 ssh 连接到服务器的所有用户的列表ssh [email protected]?

请注意,我知道这个问题,这不是我想要的!

如果它有助于服务器在如此多的不同组中拥有如此多的用户,并且在主目录下有一些组目录和这些组目录中的许多用户目录。

编辑:

请注意,我得到的结果/etc/passwd不是我想要的,如下所示:

root:x:0:0:root:/root:/bin/bash
daemon:x:1:1:daemon:/usr/sbin:/bin/sh
bin:x:2:2:bin:/bin:/bin/sh
sys:x:3:3:sys:/dev:/bin/sh
sync:x:4:65534:sync:/bin:/bin/sync
games:x:5:60:games:/usr/games:/bin/sh
man:x:6:12:man:/var/cache/man:/bin/sh
lp:x:7:7:lp:/var/spool/lpd:/bin/sh
mail:x:8:8:mail:/var/mail:/bin/sh
news:x:9:9:news:/var/spool/news:/bin/sh
uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
proxy:x:13:13:proxy:/bin:/bin/sh
www-data:x:33:33:www-data:/var/www:/bin/sh
backup:x:34:34:backup:/var/backups:/bin/sh
list:x:38:38:Mailing List Manager:/var/list:/bin/sh
irc:x:39:39:ircd:/var/run/ircd:/bin/sh
gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
libuuid:x:100:101::/var/lib/libuuid:/bin/sh
Debian-exim:x:101:103::/var/spool/exim4:/bin/false
statd:x:102:65534::/var/lib/nfs:/bin/false
sshd:x:103:65534::/var/run/sshd:/usr/sbin/nologin
shelladmin:x:1000:1000:shelladmin,,,:/home/shelladmin:/bin/bash
messagebus:x:104:106::/var/run/dbus:/bin/false
festival:x:105:29::/home/festival:/bin/false
ntp:x:106:108::/home/ntp:/bin/false

这个列表甚至不包括我自己的用户名!更不用说其他 1000 个用户了。

编辑2:

所以我和 Yaron 聊了一会儿,这里有一些关于系统的更多信息:

-bash-4.2$ ls -lsa /etc/init.d/nis
ls: cannot access /etc/init.d/nis: No such file or directory
-bash-4.2$ ls -lsa /var/yp
ls: cannot access /var/yp: No such file or directory
if it helps, this is the putput of ls -lsa /var
-bash-4.2$ ls -lsa /var
total 48
4 drwxr-xr-x 12 root root 4096 Oct 25 2016 .
4 drwxr-xr-x 22 root root 4096 Oct 25 2016 ..
4 drwxr-xr-x 2 root root 4096 Oct 26 2016 backups
4 drwxr-xr-x 10 root root 4096 Oct 25 2016 cache
4 drwxr-xr-x 34 root root 4096 Oct 25 2016 lib
4 drwxrwsr-x 2 root staff 4096 May 7 2012 local
0 lrwxrwxrwx 1 root root 9 Oct 25 2016 lock -> /run/lock
4 drwxr-xr-x 9 root root 4096 Dec 10 06:25 log
4 drwxrwsr-x 2 root mail 4096 Jul 30 00:51 mail
4 drwxr-xr-x 2 root root 4096 Nov 21 2012 opt
0 lrwxrwxrwx 1 root root 4 Oct 25 2016 run -> /run
4 drwxr-xr-x 5 root root 4096 Oct 25 2016 spool
4 drwxrwxrwt 12 root root 4096 Dec 10 08:18 tmp
4 drwxr-xr-x 2 root root 4096 Feb 16 2013 www
-bash-4.2$ getent passwd
root:x:0:0:root:/root:/bin/bash
daemon:x:1:1:daemon:/usr/sbin:/bin/sh
bin:x:2:2:bin:/bin:/bin/sh
sys:x:3:3:sys:/dev:/bin/sh
sync:x:4:65534:sync:/bin:/bin/sync
games:x:5:60:games:/usr/games:/bin/sh
man:x:6:12:man:/var/cache/man:/bin/sh
lp:x:7:7:lp:/var/spool/lpd:/bin/sh
mail:x:8:8:mail:/var/mail:/bin/sh
news:x:9:9:news:/var/spool/news:/bin/sh
uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
proxy:x:13:13:proxy:/bin:/bin/sh
www-data:x:33:33:www-data:/var/www:/bin/sh
backup:x:34:34:backup:/var/backups:/bin/sh
list:x:38:38:Mailing List Manager:/var/list:/bin/sh
irc:x:39:39:ircd:/var/run/ircd:/bin/sh
gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
libuuid:x:100:101::/var/lib/libuuid:/bin/sh
Debian-exim:x:101:103::/var/spool/exim4:/bin/false
statd:x:102:65534::/var/lib/nfs:/bin/false
sshd:x:103:65534::/var/run/sshd:/usr/sbin/nologin
shelladmin:x:1000:1000:shelladmin,,,:/home/shelladmin:/bin/bash
messagebus:x:104:106::/var/run/dbus:/bin/false
festival:x:105:29::/home/festival:/bin/false
ntp:x:106:108::/home/ntp:/bin/false
-bash-4.2$ cat /etc/nsswitch.conf
# /etc/nsswitch.conf
#
# Example configuration of GNU Name Service Switch functionality.
# If you have the `glibc-doc-reference' and `info' packages installed, try:
# `info libc "Name Service Switch"' for information about this file.

passwd: files ldap
group: files ldap
shadow: files ldap

hosts: files dns
networks: files

protocols: db files
services: db files
ethers: db files
rpc: db files

netgroup: nis
-bash-4.2$ cd /etc/sssd/
-bash: cd: /etc/sssd/: No such file or directory
ssh
  • 2 个回答
  • 112310 Views
Martin Hope
yukashima huksay
Asked: 2017-12-06 14:32:25 +0800 CST

谁在试图暴力破解我的密码?

  • 4

我正在查看我的服务器上的日志文件,我发现以下行/var/log/.auth.log.1::

pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruse      r= rhost=218.87.109.156  user=root
Failed password for root from 218.87.109.156 port 7612 ssh2
message repeated 5 times: [ Failed password for root from 218.87.109.156 port 7      612 ssh2]
error: maximum authentication attempts exceeded for root from 218.87.109.156 po      rt 7612 ssh2 [preauth]
Disconnecting: Too many authentication failures [preauth]
PAM 5 more authentication failures; logname= uid=0 euid=0 tty=ssh ruser= rhost=      218.87.109.156  user=root
PAM service(sshd) ignoring max retries; 6 > 3
pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruse      r= rhost=218.87.109.156  user=root
Failed password for root from 218.87.109.156 port 50092 ssh2
message repeated 5 times: [ Failed password for root from 218.87.109.156 port 5      0092 ssh2]
Failed password for invalid user service from 188.187.119.158 port 52722 ssh2
pam_unix(sshd:auth): check pass; user unknown
Failed password for root from 113.195.145.79 port 6500 ssh2
Received disconnect from 121.18.238.39 port 58070:11:  [preauth]
Failed password for root from 121.18.238.119 port 57538 ssh2
Failed password for root from 121.18.238.39 port 57268 ssh2
Failed password for root from 121.18.238.106 port 34360 ssh2
Disconnected from 92.222.216.31 port 58960 [preauth]
Invalid user truman from 92.222.216.31
Received disconnect from 92.222.216.31 port 33922:11: Normal Shutdown, Thank you       for playing [preauth]
input_userauth_request: invalid user truman [preauth]

并且它一直这样持续上千行!

还有我有的地方:

Nov 30 13:17:01 Aran CRON[6038]: pam_unix(cron:session): session opened for user root by (uid=0)

CRON 在这里是什么意思?那么有人可以向我解释一下这些日志是什么吗?我有危险吗?我应该怎么做才能让自己更安全?

ssh
  • 6 个回答
  • 4680 Views
Martin Hope
yukashima huksay
Asked: 2017-09-04 02:34:17 +0800 CST

如何在 ubuntu 16.04 中删除 JDK 并保留 JRE

  • 0

我已经使用以下命令在我的 VPS 上安装了 JDK-8:

sudo apt-get install openjdk-8-jdk

但是我刚刚意识到我并不真的需要 JDK,而 JRE 对我来说就足够了,因为我在 intellij 的笔记本电脑上开发我的项目并测试它们,然后我只需要在我的服务器上运行最终的 jar 文件。那么保留 JRE 并删除 JDK 其余部分的最佳方法是什么。

apt
  • 1 个回答
  • 602 Views
Martin Hope
yukashima huksay
Asked: 2017-05-30 02:24:11 +0800 CST

正在读取包列表...错误!尝试通过 apt-get 更新软件包列表

  • 2

当我尝试使用以下命令更新 DigitalOcean VPS 上的软件包列表时:

aran@Aran:~$ sudo apt-get update
Ign http://mirrors.digitalocean.com trusty InRelease
Hit http://mirrors.digitalocean.com trusty-updates InRelease
Hit http://mirrors.digitalocean.com trusty-backports InRelease
Hit http://security.ubuntu.com trusty-security InRelease
Hit http://mirrors.digitalocean.com trusty Release.gpg
Hit http://mirrors.digitalocean.com trusty Release
Hit http://mirrors.digitalocean.com trusty-updates/main Sources
Hit http://mirrors.digitalocean.com trusty-updates/restricted Sources
Hit http://mirrors.digitalocean.com trusty-updates/universe Sources
Hit http://mirrors.digitalocean.com trusty-updates/multiverse Sources
Hit http://mirrors.digitalocean.com trusty-updates/main amd64 Packages
Hit http://mirrors.digitalocean.com trusty-updates/restricted amd64 Packages
Hit http://mirrors.digitalocean.com trusty-updates/universe amd64 Packages
Hit http://mirrors.digitalocean.com trusty-updates/multiverse amd64 Packages
Hit http://mirrors.digitalocean.com trusty-updates/main i386 Packages
Hit http://mirrors.digitalocean.com trusty-updates/restricted i386 Packages
Hit http://mirrors.digitalocean.com trusty-updates/universe i386 Packages
Hit http://mirrors.digitalocean.com trusty-updates/multiverse i386 Packages
Hit http://mirrors.digitalocean.com trusty-updates/main Translation-en
Hit http://mirrors.digitalocean.com trusty-updates/multiverse Translation-en
Hit http://mirrors.digitalocean.com trusty-updates/restricted Translation-en
Hit http://mirrors.digitalocean.com trusty-updates/universe Translation-en
Hit http://mirrors.digitalocean.com trusty-backports/main Sources
Hit http://mirrors.digitalocean.com trusty-backports/restricted Sources
Hit http://mirrors.digitalocean.com trusty-backports/universe Sources
Hit http://mirrors.digitalocean.com trusty-backports/multiverse Sources
Hit http://mirrors.digitalocean.com trusty-backports/main amd64 Packages
Hit http://mirrors.digitalocean.com trusty-backports/restricted amd64 Packages
Hit http://mirrors.digitalocean.com trusty-backports/universe amd64 Packages
Hit http://mirrors.digitalocean.com trusty-backports/multiverse amd64 Packages
Hit http://mirrors.digitalocean.com trusty-backports/main i386 Packages
Hit http://mirrors.digitalocean.com trusty-backports/restricted i386 Packages
Hit http://mirrors.digitalocean.com trusty-backports/universe i386 Packages
Hit http://mirrors.digitalocean.com trusty-backports/multiverse i386 Packages
Hit http://mirrors.digitalocean.com trusty-backports/main Translation-en
Hit http://mirrors.digitalocean.com trusty-backports/multiverse Translation-en
Hit http://mirrors.digitalocean.com trusty-backports/restricted Translation-en
Hit http://mirrors.digitalocean.com trusty-backports/universe Translation-en
Hit http://security.ubuntu.com trusty-security/main Sources
Hit http://security.ubuntu.com trusty-security/universe Sources
Hit http://security.ubuntu.com trusty-security/main amd64 Packages
Hit http://security.ubuntu.com trusty-security/universe amd64 Packages
Hit http://mirrors.digitalocean.com trusty/main Sources
Hit http://mirrors.digitalocean.com trusty/restricted Sources
Hit http://mirrors.digitalocean.com trusty/universe Sources
Hit http://mirrors.digitalocean.com trusty/multiverse Sources
Hit http://mirrors.digitalocean.com trusty/main amd64 Packages
Hit http://mirrors.digitalocean.com trusty/restricted amd64 Packages
Hit http://mirrors.digitalocean.com trusty/universe amd64 Packages
Hit http://mirrors.digitalocean.com trusty/multiverse amd64 Packages
Hit http://security.ubuntu.com trusty-security/main i386 Packages
Hit http://mirrors.digitalocean.com trusty/main i386 Packages
Hit http://mirrors.digitalocean.com trusty/restricted i386 Packages
Hit http://mirrors.digitalocean.com trusty/universe i386 Packages
Hit http://mirrors.digitalocean.com trusty/multiverse i386 Packages
Hit http://mirrors.digitalocean.com trusty/main Translation-en
Hit http://mirrors.digitalocean.com trusty/multiverse Translation-en
Hit http://security.ubuntu.com trusty-security/universe i386 Packages
Hit http://security.ubuntu.com trusty-security/main Translation-en
Hit http://security.ubuntu.com trusty-security/universe Translation-en
Hit http://mirrors.digitalocean.com trusty/restricted Translation-en
Hit http://mirrors.digitalocean.com trusty/universe Translation-en
Ign http://mirrors.digitalocean.com trusty/main Translation-en_US
Ign http://mirrors.digitalocean.com trusty/multiverse Translation-en_US
Ign http://mirrors.digitalocean.com trusty/restricted Translation-en_US
Ign http://mirrors.digitalocean.com trusty/universe Translation-en_US
Reading package lists... Error!

以下是sources.list的内容:

## Note, this file is written by cloud-init on first boot of an instance
## modifications made here will not survive a re-bundle.
## if you wish to make changes you can:
## a.) add 'apt_preserve_sources_list: true' to /etc/cloud/cloud.cfg
##     or do the same in user-data
## b.) add sources in /etc/apt/sources.list.d
## c.) make changes to template file /etc/cloud/templates/sources.list.tmpl
#

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://mirrors.digitalocean.com/ubuntu trusty main restricted
deb-src http://mirrors.digitalocean.com/ubuntu trusty main restricted

## Major bug fix updates produced after the final release of the
## distribution.
deb http://mirrors.digitalocean.com/ubuntu trusty-updates main restricted
deb-src http://mirrors.digitalocean.com/ubuntu trusty-updates main restricted

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://mirrors.digitalocean.com/ubuntu trusty universe
deb-src http://mirrors.digitalocean.com/ubuntu trusty universe
deb http://mirrors.digitalocean.com/ubuntu trusty-updates universe
deb-src http://mirrors.digitalocean.com/ubuntu trusty-updates universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://mirrors.digitalocean.com/ubuntu trusty multiverse
deb-src http://mirrors.digitalocean.com/ubuntu trusty multiverse
deb http://mirrors.digitalocean.com/ubuntu trusty-updates multiverse
deb-src http://mirrors.digitalocean.com/ubuntu trusty-updates multiverse

## Uncomment the following two lines to add software from the 'backports'
## repository.
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://mirrors.digitalocean.com/ubuntu trusty-backports main restricted universe multive$
deb-src http://mirrors.digitalocean.com/ubuntu trusty-backports main restricted universe mul$

## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu trusty partner
# deb-src http://archive.canonical.com/ubuntu trusty partner

deb http://security.ubuntu.com/ubuntu trusty-security main
deb-src http://security.ubuntu.com/ubuntu trusty-security main
deb http://security.ubuntu.com/ubuntu trusty-security universe
deb-src http://security.ubuntu.com/ubuntu trusty-security universe
# deb http://security.ubuntu.com/ubuntu trusty-security multiverse
# deb-src http://security.ubuntu.com/ubuntu trusty-security multiverse

以下是 /var/log/apt/term.log 中的内容:

Log started: 2017-05-29  01:21:39
Selecting previously unselected package libxslt1.1:amd64.
(Reading database ... ^M(Reading database ... 5%^M(Reading database ... 10%^M(Reading databa$
Preparing to unpack .../libxslt1.1_1.1.28-2ubuntu0.1_amd64.deb ...
Unpacking libxslt1.1:amd64 (1.1.28-2ubuntu0.1) ...
Selecting previously unselected package nginx-common.
Preparing to unpack .../nginx-common_1.4.6-1ubuntu3.7_all.deb ...
Unpacking nginx-common (1.4.6-1ubuntu3.7) ...
Selecting previously unselected package nginx-core.
Preparing to unpack .../nginx-core_1.4.6-1ubuntu3.7_amd64.deb ...
Unpacking nginx-core (1.4.6-1ubuntu3.7) ...
Selecting previously unselected package nginx.
Preparing to unpack .../nginx_1.4.6-1ubuntu3.7_all.deb ...
Unpacking nginx (1.4.6-1ubuntu3.7) ...
Processing triggers for ufw (0.34~rc-0ubuntu2) ...
Processing triggers for ureadahead (0.100.0-16) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up libxslt1.1:amd64 (1.1.28-2ubuntu0.1) ...
Setting up nginx-common (1.4.6-1ubuntu3.7) ...
Setting up nginx-core (1.4.6-1ubuntu3.7) ...
Setting up nginx (1.4.6-1ubuntu3.7) ...
Processing triggers for libc-bin (2.19-0ubuntu6.11) ...
Log ended: 2017-05-29  01:21:44

Log started: 2017-05-29  01:22:35
Selecting previously unselected package php5-fpm.
(Reading database ... ^M(Reading database ... 5%^M(Reading database ... 10%^M(Reading databa$
Preparing to unpack .../php5-fpm_5.5.9+dfsg-1ubuntu4.21_amd64.deb ...
Unpacking php5-fpm (5.5.9+dfsg-1ubuntu4.21) ...
Processing triggers for ureadahead (0.100.0-16) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up php5-fpm (5.5.9+dfsg-1ubuntu4.21) ...

Creating config file /etc/php5/fpm/php.ini with new version
php5_invoke: Enable module json for fpm SAPI
php5_invoke: Enable module gd for fpm SAPI
php5_invoke: Enable module mysqli for fpm SAPI
php5_invoke: Enable module pdo_mysql for fpm SAPI
php5_invoke: Enable module pdo for fpm SAPI
php5_invoke: Enable module opcache for fpm SAPI
php5_invoke: Enable module ssh2 for fpm SAPI
php5_invoke: Enable module readline for fpm SAPI
php5_invoke: Enable module mysql for fpm SAPI
php5-fpm start/running, process 7326
Processing triggers for ureadahead (0.100.0-16) ...
Log ended: 2017-05-29  01:22:37

以下是同一目录下 history.log 中的日志:

Start-Date: 2017-05-29  01:21:39
Commandline: apt-get install nginx
Install: nginx-core:amd64 (1.4.6-1ubuntu3.7, automatic), libxslt1.1:amd64 (1.1.28-2ubuntu0.1$
End-Date: 2017-05-29  01:21:44

Start-Date: 2017-05-29  01:22:35
Commandline: apt-get install php5-fpm
Install: php5-fpm:amd64 (5.5.9+dfsg-1ubuntu4.21)
End-Date: 2017-05-29  01:22:37
apt
  • 2 个回答
  • 8435 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