我有一台运行 Ubuntu 20 的小型办公室/家庭服务器。不幸的是,全国各地经常发生持续停电。无论如何,UPS 没有时间充电,当服务器恢复时,似乎许多服务尚未启动(Apache、NFS、Samba、Webmin 等)。
我可以通过 SSH 访问该机器,但不能通过 SFTP、SMB 或 NFS 访问。
以下是 dmesg 列出的错误。我该如何追踪问题所在?我希望避免完全重新安装,但如果必须,那么希望不必复制所有数据(我确实有备份,在服务器的镜像驱动器上,以及每周的外部备份。但外部仍然是 USB 2,所以速度非常慢。而且必须重新设置每个服务,非常耗时,所以如果有办法解决这个问题,那就太好了。
德尔福能源公司:
[ 1.246819] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
[ 1.249414] ACPI BIOS Error (bug): Could not resolve symbol [\_SB.PCI0.SAT0.SPT0._GTF.DSSP], AE_NOT_FOUND (20200528/psargs-330)
[ 1.252896] No Local Variables are initialized for Method [_GTF]
[ 1.254043] No Arguments are initialized for method [_GTF]
[ 1.255153] ACPI Error: Aborting method \_SB.PCI0.SAT0.SPT0._GTF due to previous error (AE_NOT_FOUND) (20200528/psparse-529)
[ 1.256301] ata6: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
[ 1.257539] ata1.00: ATA-8: WDC WD10EURX-63FH1Y0, 01.01A01, max UDMA/133
[ 1.258664] ata1.00: 1953525168 sectors, multi 16: LBA48 NCQ (depth 32), AA
[ 1.260582] ACPI BIOS Error (bug): Could not resolve symbol [\_SB.PCI0.SAT0.SPT0._GTF.DSSP], AE_NOT_FOUND (20200528/psargs-330)
[ 1.262750] No Local Variables are initialized for Method [_GTF]
[ 1.263847] No Arguments are initialized for method [_GTF]
[ 1.264753] ACPI Error: Aborting method \_SB.PCI0.SAT0.SPT0._GTF due to previous error (AE_NOT_FOUND) (20200528/psparse-529)
[ 1.265693] ACPI BIOS Error (bug): Could not resolve symbol [\_SB.PCI0.SAT0.SPT5._GTF.DSSP], AE_NOT_FOUND (20200528/psargs-330)
[ 1.267859] No Local Variables are initialized for Method [_GTF]
[ 1.269069] No Arguments are initialized for method [_GTF]
[ 1.270285] ACPI Error: Aborting method \_SB.PCI0.SAT0.SPT5._GTF due to previous error (AE_NOT_FOUND) (20200528/psparse-529)
[ 1.271625] ata1.00: configured for UDMA/133
[ 1.272591] ata6.00: ATA-8: SAMSUNG HD253GI, 1AJ10001, max UDMA/133
[ 1.272679] scsi 0:0:0:0: Direct-Access ATA WDC WD10EURX-63F 1A01 PQ: 0 ANSI: 5
[ 1.273769] ata6.00: 488397168 sectors, multi 16: LBA48 NCQ (depth 32), AA
[ 1.275142] sd 0:0:0:0: [sda] 1953525168 512-byte logical blocks: (1.00 TB/932 GiB)
[ 1.276444] sd 0:0:0:0: Attached scsi generic sg0 type 0
[ 1.277104] sd 0:0:0:0: [sda] 4096-byte physical blocks
[ 1.279171] sd 0:0:0:0: [sda] Write Protect is off
[ 1.280331] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[ 1.280347] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 1.283603] ACPI BIOS Error (bug): Could not resolve symbol [\_SB.PCI0.SAT0.SPT5._GTF.DSSP], AE_NOT_FOUND (20200528/psargs-330)
[ 1.285532] No Local Variables are initialized for Method [_GTF]
[ 1.286870] No Arguments are initialized for method [_GTF]
[ 1.288206] ACPI Error: Aborting method \_SB.PCI0.SAT0.SPT5._GTF due to previous error (AE_NOT_FOUND) (20200528/psparse-529)
[ 1.289804] ata6.00: configured for UDMA/133
我尝试过手动重启服务,但都失败了。每个服务的状态都显示不出来。尝试 apt update 无法解析存储库名称。与 ping 一样,我可以获取 IP 地址,但主机名对外部站点也不起作用。
适当更新:
Err:2 http://archive.canonical.com/ubuntu groovy InRelease
Could not resolve 'archive.canonical.com'
如果这是中断的 apt,我还尝试了 apt dist-upgrade,但出现了这个错误。
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
W: Not using locking for read only lock file /var/lib/dpkg/lock-frontend
W: Not using locking for read only lock file /var/lib/dpkg/lock
W: chown to _apt:root of directory /var/cache/apt/archives/partial failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chmod 0700 of directory /var/cache/apt/archives/partial failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chown to _apt:root of directory /var/lib/apt/lists/auxfiles failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chmod 0755 of directory /var/lib/apt/lists/auxfiles failed - SetupAPTPartialDirectory (30: Read-only file system)
W: Not using locking for read only lock file /var/cache/apt/archives/lock
systemctl 状态 apache2
● apache2.service - The Apache HTTP Server
Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2021-03-16 14:54:45 SAST; 6h ago
Docs: https://httpd.apache.org/docs/2.4/
Process: 1618 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)
Warning: journal has been rotated since unit was started, output may be incomplete.
journalctl-u apache2
-- Reboot --
Mar 16 01:15:40 samdb-dev systemd[1]: Starting The Apache HTTP Server...
Mar 16 01:16:17 samdb-dev systemd[1]: Started The Apache HTTP Server
systemctl 状态 dovecot
● dovecot.service - Dovecot IMAP/POP3 email server
Loaded: loaded (/lib/systemd/system/dovecot.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2021-03-16 14:54:22 SAST; 6h ago
Docs: man:dovecot(1)
http://wiki2.dovecot.org/
Process: 1568 ExecStart=/usr/sbin/dovecot -F (code=exited, status=226/NAMESPACE)
Main PID: 1568 (code=exited, status=226/NAMESPACE)
Warning: journal has been rotated since unit was started, output may be incomplete.
journalctl-u dovecot
-- Reboot --
Mar 16 01:15:40 samdb-dev systemd[1]: Starting Dovecot IMAP/POP3 email server...
Mar 16 01:15:53 samdb-dev dovecot[745]: master: Dovecot v2.3.11.3 (502c39af9) starting up for imap (core dumps disabled)
Mar 16 01:15:55 samdb-dev systemd[1]: Started Dovecot IMAP/POP3 email server.
Mar 16 08:01:25 samdb-dev auth[43140]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:25 samdb-dev auth[43140]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:26 samdb-dev dovecot[882]: imap-login: Login: user=<ken>, method=PLAIN, rip=192.168.0.94, lip=192.168.0.100, mpid=43141, TLS, session=<E3a8GKG9A8TAqABe>
Mar 16 08:01:27 samdb-dev auth[43140]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:27 samdb-dev auth[43140]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:27 samdb-dev dovecot[882]: imap-login: Login: user=<ken>, method=PLAIN, rip=192.168.0.94, lip=192.168.0.100, mpid=43142, TLS, session=<nPrMGKG9AsTAqABe>
Mar 16 08:01:42 samdb-dev auth[43140]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:42 samdb-dev auth[43140]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:42 samdb-dev auth[43180]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:42 samdb-dev dovecot[882]: imap-login: Login: user=<merle>, method=PLAIN, rip=192.168.0.94, lip=192.168.0.100, mpid=43181, TLS, session=<3IayGaG9BcTAqABe>
Mar 16 08:01:42 samdb-dev auth[43180]: pam_unix(dovecot:auth): Couldn't open /etc/securetty: No such file or directory
Mar 16 08:01:42 samdb-dev dovecot[882]: imap-login: Login: user=<merle>, method=PLAIN, rip=192.168.0.94, lip=192.168.0.100, mpid=43182, TLS, session=<s6eyGaG9BsTAqABe>
Mar 16 08:01:54 samdb-dev dovecot[882]: imap(merle)<43182><s6eyGaG9BsTAqABe>: Logged out in=274 out=9658 deleted=0 expunged=0 trashed=0 hdr_count=1 hdr_bytes=5553 body_count=0 body_bytes=0
Mar 16 08:01:54 samdb-dev dovecot[882]: imap(merle)<43181><3IayGaG9BcTAqABe>: Logged out in=62 out=616 deleted=0 expunged=0 trashed=0 hdr_count=0 hdr_bytes=0 body_count=0 body_bytes=0
Mar 16 08:01:54 samdb-dev dovecot[882]: imap(ken)<43142><nPrMGKG9AsTAqABe>: Logged out in=236 out=25327 deleted=0 expunged=0 trashed=0 hdr_count=1 hdr_bytes=6130 body_count=0 body_bytes=0
Mar 16 08:01:54 samdb-dev dovecot[882]: imap(ken)<43141><E3a8GKG9A8TAqABe>: Logged out in=119 out=958 deleted=0 expunged=0 trashed=0 hdr_count=0 hdr_bytes=0 body_count=0 body_bytes=0
我通常运行一个 Web 服务器、MySQL、PostgreSQL、webmin、dovecot IMAP。
非常感谢您的意见/见解。提前谢谢您