假设一个人希望有一个被阻止的 IP 地址列表。
我看到了以下示例脚本:
BLOCKDB="/path/to/ip.blocked.file"
# omit comments lines
IPS=$(grep -Ev "^#" $BLOCKDB)
for i in $IPS
do
iptables -A INPUT -s $i -j DROP
iptables -A OUTPUT -d $i -j DROP
done
Run Code Online (Sandbox Code Playgroud)
几千行,转换成几千个iptables条目,理智吗?
上限是多少,超过这个上限,系统效率会受到显着影响?
刚买了一台装有 NVidia GForce N430 的新电脑,并安装了一个全新的 Ubuntu 11.10 amd64。
我还使用“附加驱动程序”apt 启用了 nvidia 驱动程序,并且在“正常”模式下一切正常,但是,我想旋转我的屏幕,但未能通过。
IIRC,在以前的安装中,曾经有一个在nvidia-settingsUI 中旋转的条目,但在这个版本中没有。
我正在使用两个屏幕,并且愿意使用它们顺时针旋转 90 度(纵向与横向)。
我正在转储我的 X11/xorg.cong 文件,如果有人能告诉在哪里添加该Option "RandRRotation" "True"行,我将不胜感激。
顺便一提,
$ xrandr -o right
Run Code Online (Sandbox Code Playgroud)
打印出来
X Error of failed request: BadMatch (invalid parameter attributes)
Major opcode of failed request: 153 (RANDR)
Minor opcode of failed request: 2 (RRSetScreenConfig)
Serial number of failed request: 14
Current serial number in output stream: 14
Run Code Online (Sandbox Code Playgroud)
/etc/X11/xorg.conf 的内容
$ cat /etc/X11/xorg.conf
# nvidia-settings: X configuration file generated by …Run Code Online (Sandbox Code Playgroud) 在具有 2GB 存储空间的设备上,每 MB 都会被计算在内。
我想知道这/var/lib/ureadahead/debugfs在我的系统上做了什么,有没有办法避免它的存在。
请注意,此挂载点占用1.2 GB
# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda1 1.8G 1.2G 546M 68% /
none 995M 224K 995M 1% /dev
none 1000M 0 1000M 0% /dev/shm
none 1000M 136K 1000M 1% /var/run
none 1000M 0 1000M 0% /var/lock
none 1000M 0 1000M 0% /lib/init/rw
none 1.8G 1.2G 546M 68% /var/lib/ureadahead/debugfs
# cat /proc/self/mountinfo
15 19 0:0 / /sys rw,nosuid,nodev,noexec,relatime - sysfs none rw
16 19 0:3 / …Run Code Online (Sandbox Code Playgroud) 鉴于这一事实shred在 ext3 上无效,我想知道现在有哪些可用的替代方案。
$ man shred\n...\n\n CAUTION: Note that shred relies on a very important assumption: that\n the file system overwrites data in place. This is the traditional way\n to do things, but many modern file system designs do not satisfy this\n assumption. The following are examples of file systems on which shred\n is not effective, or is not guaranteed to be effective in all file sys\xe2\x80\x90\n tem modes:\n\n * log-structured or journaled file systems, such as …Run Code Online (Sandbox Code Playgroud) 网络管理器显示消息“无线被硬件开关禁用”,而笔记本电脑上没有开关以禁用无线。
下面是 lshw 输出,它可能有助于找到解决方案
$ sudo lshw -C network
...
*-network DISABLED
description: Wireless interface
product: Centrino Advanced-N 6200
vendor: Intel Corporation
physical id: 0
bus info: pci@0000:0a:00.0
logical name: wlan0
version: 35
serial: 58:94:6b:14:25:c8
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
configuration: broadcast=yes driver=iwlagn driverversion=2.6.38-8-generic firmware=9.221.4.1 build 25532 latency=0 link=no multicast=yes wireless=IEEE 802.11abgn
resources: irq:41 memory:ead00000-ead01fff
Run Code Online (Sandbox Code Playgroud) 我刚刚通过Hacker News看到这篇文章,想知道有什么大惊小怪的?Ubuntu 永远是免费的,对吧?这是一个没有人打算打破的承诺。更重要的是,Ubuntu 本身将保持与今天相同的许可,对吗?
如果有人能说出这将如何影响我们对伟大的 Ubuntu 的使用,我将不胜感激。
在我正在构建的网络设备上,基于 Ubuntu 服务器,我希望执行以下自定义:
我怎样才能获得上述选项之一