日記/2013-10-18
2013-10-18 (金) 14:39:18
WiFiを遮断する†
先日購入した中古のThinkPadX61、Bios画面でWiFiをoffにしても認識されてしまう。
WiFiは邪魔なので次のように対策。(Biosの更新をすれば良さそうなのだが面倒なので)
/etc/udev/rules.d/70-persistent-net.rulesを見ると、
# This file was automatically generated by the /lib/udev/write_net_rules # program, run by the persistent-net-generator.rules rules file. # # This file was automatically generated by the /lib/udev/write_net_rules # program, run by the persistent-net-generator.rules rules file. # # You can modify it, as long as you keep each rule on a single # line, and change only the value of the NAME= key. # You can modify it, as long as you keep each rule on a single # line, and change only the value of the NAME= key. # PCI device 0x8086:0x1049 (e1000e) SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:16:d3:c6:41:9c", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0" # PCI device 0x168c:0x1014 (ath5k) SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:1e:4c:03:1a:18", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="wlan*", NAME="wlan0"
WiFiはwlan0、ドライバはath5kで自動認識されている。
/etc/modprobe.d/blacklist.confを開いて末尾に、
blacklist ath5k
と追記。
/etc/udev/rules.d/70-persistent-net.rulesを
# This file was automatically generated by the /lib/udev/write_net_rules # program, run by the persistent-net-generator.rules rules file. # # You can modify it, as long as you keep each rule on a single # line, and change only the value of the NAME= key.
としてrebootする。
reboot後の/etc/udev/rules.d/70-persistent-net.rulesを見ると、
# This file was automatically generated by the /lib/udev/write_net_rules # program, run by the persistent-net-generator.rules rules file. # # This file was automatically generated by the /lib/udev/write_net_rules # program, run by the persistent-net-generator.rules rules file. # # You can modify it, as long as you keep each rule on a single # line, and change only the value of the NAME= key. # You can modify it, as long as you keep each rule on a single # line, and change only the value of the NAME= key. # PCI device 0x8086:0x1049 (e1000e) SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:16:d3:c6:41:9c", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
となり、WiFiは認識されなくなった。