[求助]关于usb无线网卡

系统版本:openSUSE leap 42.3 & KDE
如题,我遇到了一个较为神奇的 BUG
每次开机我都得:Yast-> 网络设置, 将 NetWorkManager 切换为 Wicked 然后再次切换回来才可以激活无线上网,不然系统托盘那里压根不显示有关无线上网的东西(包括 WIFI 的那个小图标,附近可连接的 WIFI)

** 在切换之前 **
我尝试执行:
hwinfo --wlan --short
有关于 wlan 的硬件信息
执行
ifconfig wlan0 up
以及
ifconfig -a
有 wlan0 的信息
但是,托盘那里就是死活不显示无线上网的相关选项

好像是开机的时候没有加载 wifi 模块
因为我有次用 wifi 正常上网了后拔掉 usb 无线网卡,再次插入也需要重复上述操作

@hmqs

拜托能不能贴下网卡能用和不能用的时候,分别的 “lsmod” 命令结果。要是内核模块的问题,再教你把内核模块编译进 initrd 从而开机就能自动识别

从我的 iPhone 发送,使用 Tapatalk

1赞

因为我的 USB 无线网卡是安装 openSUSE 的时候就插着的,所以我自己并没有遇到这个问题

从我的 iPhone 发送,使用 Tapatalk

能上网时:

 Module                  Size  Used by
af_packet              45056  6 
iscsi_ibft             16384  0 
iscsi_boot_sysfs       20480  1 iscsi_ibft
joydev                 20480  0 
fuse                  106496  3 
msr                    16384  0 
r8188eu               487424  0 
cfg80211              614400  1 r8188eu
rfkill                 28672  5 cfg80211
snd_hda_codec_hdmi     57344  4 
xfs                  1077248  1 
libcrc32c              16384  1 xfs
snd_hda_codec_realtek    94208  1 
snd_hda_codec_generic    81920  1 snd_hda_codec_realtek
snd_hda_intel          45056  5 
snd_hda_codec         147456  4 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel
snd_hda_core           81920  5 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
snd_hwdep              16384  1 snd_hda_codec
snd_pcm               135168  4 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_core
snd_timer              36864  1 snd_pcm
snd                    90112  18 snd_hda_codec_realtek,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
iTCO_wdt               16384  0 
r8169                  90112  0 
mii                    16384  1 r8169
gpio_ich               16384  0 
iTCO_vendor_support    16384  1 iTCO_wdt
i7core_edac            28672  0 
lpc_ich                24576  0 
edac_core              65536  2 i7core_edac
mfd_core               16384  1 lpc_ich
intel_powerclamp       16384  0 
i2c_i801               28672  0 
coretemp               16384  0 
i5500_temp             16384  0 
shpchp                 36864  0 
kvm_intel             184320  0 
kvm                   606208  1 kvm_intel
irqbypass              16384  1 kvm
crc32c_intel           24576  1 
fjes                   32768  0 
soundcore              16384  1 snd
pcspkr                 16384  0 
processor              49152  0 
ext4                  655360  1 
crc16                  16384  1 ext4
jbd2                  118784  1 ext4
mbcache                16384  2 ext4
sr_mod                 24576  0 
sd_mod                 57344  4 
cdrom                  61440  1 sr_mod
serio_raw              16384  0 
nouveau              1691648  9 
video                  40960  1 nouveau
mxm_wmi                16384  1 nouveau
ahci                   36864  3 
libahci                36864  1 ahci
wmi                    16384  2 mxm_wmi,nouveau
i2c_algo_bit           16384  1 nouveau
drm_kms_helper        167936  1 nouveau
libata                274432  2 ahci,libahci
syscopyarea            16384  1 drm_kms_helper
ehci_pci               16384  0 
sysfillrect            16384  1 drm_kms_helper
uhci_hcd               49152  0 
sysimgblt              16384  1 drm_kms_helper
fb_sys_fops            16384  1 drm_kms_helper
ehci_hcd               81920  1 ehci_pci
ttm                   110592  1 nouveau
usbcore               270336  4 uhci_hcd,r8188eu,ehci_hcd,ehci_pci
usb_common             16384  1 usbcore
drm                   397312  12 ttm,drm_kms_helper,nouveau
button                 16384  1 nouveau
sg                     40960  0 
scsi_mod              249856  4 sg,libata,sd_mod,sr_mod
autofs4                45056  2

不能上网时:

 Module                  Size  Used by
fuse                  106496  3 
msr                    16384  0 
r8188eu               487424  0 
cfg80211              614400  1 r8188eu
rfkill                 28672  4 cfg80211
snd_hda_codec_hdmi     57344  4 
xfs                  1077248  1 
libcrc32c              16384  1 xfs
snd_hda_codec_realtek    94208  1 
snd_hda_codec_generic    81920  1 snd_hda_codec_realtek
snd_hda_intel          45056  5 
snd_hda_codec         147456  4 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel
snd_hda_core           81920  5 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
snd_hwdep              16384  1 snd_hda_codec
snd_pcm               135168  4 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_core
snd_timer              36864  1 snd_pcm
snd                    90112  18 snd_hda_codec_realtek,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
iTCO_wdt               16384  0 
r8169                  90112  0 
mii                    16384  1 r8169
gpio_ich               16384  0 
iTCO_vendor_support    16384  1 iTCO_wdt
i7core_edac            28672  0 
lpc_ich                24576  0 
edac_core              65536  2 i7core_edac
mfd_core               16384  1 lpc_ich
intel_powerclamp       16384  0 
i2c_i801               28672  0 
coretemp               16384  0 
i5500_temp             16384  0 
shpchp                 36864  0 
kvm_intel             184320  0 
kvm                   606208  1 kvm_intel
irqbypass              16384  1 kvm
crc32c_intel           24576  1 
fjes                   32768  0 
soundcore              16384  1 snd
pcspkr                 16384  0 
processor              49152  0 
ext4                  655360  1 
crc16                  16384  1 ext4
jbd2                  118784  1 ext4
mbcache                16384  2 ext4
sr_mod                 24576  0 
sd_mod                 57344  4 
cdrom                  61440  1 sr_mod
serio_raw              16384  0 
nouveau              1691648  6 
video                  40960  1 nouveau
mxm_wmi                16384  1 nouveau
ahci                   36864  3 
libahci                36864  1 ahci
wmi                    16384  2 mxm_wmi,nouveau
i2c_algo_bit           16384  1 nouveau
drm_kms_helper        167936  1 nouveau
libata                274432  2 ahci,libahci
syscopyarea            16384  1 drm_kms_helper
ehci_pci               16384  0 
sysfillrect            16384  1 drm_kms_helper
uhci_hcd               49152  0 
sysimgblt              16384  1 drm_kms_helper
fb_sys_fops            16384  1 drm_kms_helper
ehci_hcd               81920  1 ehci_pci
ttm                   110592  1 nouveau
usbcore               270336  4 uhci_hcd,r8188eu,ehci_hcd,ehci_pci
usb_common             16384  1 usbcore
drm                   397312  9 ttm,drm_kms_helper,nouveau
button                 16384  1 nouveau
sg                     40960  0 
scsi_mod              249856  4 sg,libata,sd_mod,sr_mod
autofs4                45056  2

@marguerite
如上

我在安装的时候网络设备那里就没有 USB 无线网卡
当我切换一下网络管理就出来了
现在我用 wicked 管理,开机自动联网
:sweat:

af_packet
iscsi_ibft
iscsi_boot_sysfs
joydev

这是两个 diff 的结果,成功运行时多了这些 module。

你可以先 “su” 然后输入 root 密码进入 root 模式,然后:

uname -r

看运行的内核版本

cd /boot
ls -l

找到比如 initrd -> initrd-4.10.1-2-default,要后面那个

dracut --add-drivers af_packet iscsi_ibft iscsi_boot_sysfs joydev --rebuild /boot/initrd-4.10.1-2-default

重制一下 initramfs。

最后把 wicked 切换回 NetworkManager 再重启下试试。

从我的 iPhone 发送,使用 Tapatalk

其它的内核模块,比如 nvidia 的三个私有模块,也可以这么编译进 initramfs。

从我的 iPhone 发送,使用 Tapatalk

我安装 NV 的私有驱动,使用一段时间后,KDE 必死
登录时候 Plasma 已经不见了,留了一个 lceWM 给我,也无法登录
现在认怂,老老实实用开源驱动
:weary:

把 nouveau 写 /etc/modprobe.d/50-blacklist.conf 了吗?我是写 blacklist,然后重制 initramfs 把私有的内核模块编译进去,然后用 -omit 把 nouveau 从 initramfs 里剔出去。

从我的 iPhone 发送,使用 Tapatalk

不想试了,我感觉开源和闭源驱动差不多
至少我还没感觉差异在哪

老卡差不多,但是 960 往上的好像开源还没支持

从我的 iPhone 发送,使用 Tapatalk

玛丽姐,现在我的系统版本是42.3,开机依旧如此
依照你的方法添加三个模块(af_packet iscsi_ibft iscsi_boot_sysfs)时报错

touch: option requires an argument -- 'd'
Try 'touch --help' for more information.
dracut: touch -d failed.
dracut: Cannot find module directory /lib/modules/iscsi_boot_sysfs/
dracut: and --no-kernel was not specified

单独一个一个执行提示

touch: option requires an argument -- 'd'
Try 'touch --help' for more information.
dracut: touch -d failed.
dracut: Executing: /usr/bin/dracut -d af_packet --rebuild /boot/initrd-4.4.132-53-default
dracut: *** Including module: bash ***
dracut: *** Including module: systemd ***
此处省略

但是我重启后sudo lsmod还是没有这些模块:sob::weary:

@hmqs

是我的锅,是 —add-drivers 不是 -d。

 dracut --add-drivers af_packet iscsi_ibft iscsi_boot_sysfs joydev --rebuild /boot/initrd-4.10.1-2-default

@marguerite
然后现在启动进不了系统,加载完内核就这样了,之前已经持续了十几分钟,我强制关闭了,就是这样

好吧,我重装了系统
opensuse leap 15.0 livecd安装下没有这个问题

1赞