这是从我家到sina.com.cn
.
traceroute -n sina.com.cn
traceroute to sina.com.cn (202.108.33.60), 30 hops max, 60 byte packets
1 192.168.31.1 0.476 ms 0.587 ms 0.695 ms
2 140.0.5.1 2.557 ms 2.699 ms 3.065 ms
3 221.11.155.65 4.501 ms * 221.11.165.9 5.045 ms
4 * 221.11.156.18 26.480 ms 221.11.165.233 22.950 ms
5 219.158.9.97 14.176 ms * 219.158.19.149 21.472 ms
6 219.158.9.97 18.142 ms 219.158.8.81 44.856 ms 52.539 ms
7 124.65.194.190 53.162 ms 219.158.8.81 50.614 ms 124.65.194.190 47.266 ms
8 124.65.194.190 50.760 ms 61.148.143.26 …
Run Code Online (Sandbox Code Playgroud) 我的操作系统:debian9。
我磁盘上的文件系统:
$ sudo blkid | awk '{print $1 ,$3}'
/dev/sda2: TYPE="ext4"
/dev/sda1: TYPE="vfat"
/dev/sda3: TYPE="ext4"
/dev/sda4: TYPE="ext4"
/dev/sda5: TYPE="swap"
Run Code Online (Sandbox Code Playgroud)
现在chattr +i
为我的/etc/resolv.conf
:
sudo chattr +i /etc/resolv.conf
chattr: Operation not supported while reading flags on /etc/resolv.conf
ls -al /etc/resolv.conf
lrwxrwxrwx 1 root root 31 Jan 8 15:08 /etc/resolv.conf -> /etc/resolvconf/run/resolv.conf
sudo mount -o remount,acl /
sudo chattr +i /etc/resolvconf/run/resolv.conf
chattr: Inappropriate ioctl for device while reading flags on /etc/resolvconf/run/resolv.conf
Run Code Online (Sandbox Code Playgroud)
如何设置 chattr +i
为我的/etc/resolve.conf
?
/dev/sda1
对于 …
环境:debian9+LAMP+wordpress4.9.3,搭建在本地PC上,自己用。
cat /var/log/apache2/error.log
[Mon Feb 05 09:42:09.965635 2018] [mpm_prefork:notice] [pid 1083] AH00163: Apache/2.4.25 (Debian) configured -- resuming normal operations
[Mon Feb 05 09:42:09.965658 2018] [core:notice] [pid 1083] AH00094: Command line: '/usr/sbin/apache2'
[Mon Feb 05 14:41:47.057389 2018] [mpm_prefork:notice] [pid 1083] AH00169: caught SIGTERM, shutting down
Run Code Online (Sandbox Code Playgroud)
错误日志中有很多 AH00169 和 AH00163 以及一些 AH00094。每天几乎有 40 行错误信息。
它被一个人使用,我!
使用 apachectl 检查所有配置。
sudo apachectl configtest
Syntax OK
Run Code Online (Sandbox Code Playgroud)
一些重要的配置文件:
文件 000-default.conf
cat /etc/apache2/sites-available/000-default.conf
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Run Code Online (Sandbox Code Playgroud)文件 apache2.conf …
ssh -p yyyy root@xxxxxxxxx
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Offending ECDSA key in /home/debian8/.ssh/known_hosts:28
remove with: ssh-keygen -f "/home/user/.ssh/known_hosts" -R [xxxx]:yyyy
ECDSA host key for [xxxxxxxx]:yyyy has changed and you have requested strict checking.
Host key verification failed.
Run Code Online (Sandbox Code Playgroud)
按照警告说的去做。
$ ssh-keygen -f "/home/user/.ssh/known_hosts" -R [xxxx]:yyyy
/home/user/.ssh/known_hosts is not a valid known_hosts file.
Not replacing existing known_hosts file because of errors
Run Code Online (Sandbox Code Playgroud)
现在要执行哪个命令?
以下所有命令都在我的 debian 终端中运行。
ls /dev |grep ptmx
/dev/ptmx
ls /dev/pts
0 1 ptmx
Run Code Online (Sandbox Code Playgroud)
/dev/ptmx
和 和有/dev/pts/ptmx
什么区别?
ls /dev/tty* |sort
/dev/tty
/dev/tty0
/dev/tty1
/dev/tty10
Run Code Online (Sandbox Code Playgroud)
/dev/tty 和 /dev/tty0 (/dev/tty1....) 之间有关系吗?
/dev/tty 控制所有其他 /dev/tty[number] ?
该命令useradd new
将创建 /home/new 目录。
有没有办法在执行时创建 /home/new 和 /home/new/check 目录useradd new
?
我不想每次创建新用户时都为作业编写两个命令。
useradd new
mkdir /home/new/check
Run Code Online (Sandbox Code Playgroud) debian ×2
apache-httpd ×1
router ×1
ssh ×1
traceroute ×1
tty ×1
useradd ×1
wordpress ×1
xattr ×1