2017-08-15 72 views
0

我想在ubuntu core 16.04上配置一個帶有蜂窩接口的新設備。我運行了NMCLI軟件包。在我加入我的連接我檢查了接口NMCLI設備不可用

# nmcli dev 
DEVICE TYPE  STATE   CONNECTION   
eth1  ethernet connected  Wired connection 1 
wlan0  wifi  disconnected --     
eth0  ethernet unavailable --     
cdc-wdm0 gsm  unavailable --     
lo  loopback unmanaged  --  

我說我的連接:

nmcli con add type gsm ifname cdc-wdm0 con-name MyConnection apn myapn.com 

最後我試圖把連接通過運行:

nmclil con up MyConnection 
Error: Connection activation failed: No suitable device found for this connection 

而且我已經貼了應用Config的輸出:

# nmcli -p con show MyConnection 

        Connection profile details (MyConnection) 

connection.id:       MyConnection 
connection.uuid:      25dc3eec-ca8a-4861-bfcc-089d558972d4 
connection.interface-name:    cdc-wdm0 
connection.type:      gsm 
connection.autoconnect:     yes 
connection.autoconnect-priority:  0 
connection.timestamp:     0 
connection.read-only:     no 
connection.permissions:     
connection.zone:      -- 
connection.master:      -- 
connection.slave-type:     -- 
connection.autoconnect-slaves:   -1 (default) 
connection.secondaries:     
connection.gateway-ping-timeout:  0 
connection.metered:      unknown 
connection.lldp:      -1 (default) 

ipv4.method:       auto 
ipv4.dns:        
ipv4.dns-search:       
ipv4.dns-options:      (default) 
ipv4.addresses:       
ipv4.gateway:       -- 
ipv4.routes:        
ipv4.route-metric:      -1 
ipv4.ignore-auto-routes:    no 
ipv4.ignore-auto-dns:     no 
ipv4.dhcp-client-id:     -- 
ipv4.dhcp-timeout:      0 
ipv4.dhcp-send-hostname:    yes 
ipv4.dhcp-hostname:      -- 
ipv4.dhcp-fqdn:       -- 
ipv4.never-default:      no 
ipv4.may-fail:       yes 
ipv4.dad-timeout:      -1 (default) 

ipv6.method:       auto 
ipv6.dns:        
ipv6.dns-search:       
ipv6.dns-options:      (default) 
ipv6.addresses:       
ipv6.gateway:       -- 
ipv6.routes:        
ipv6.route-metric:      -1 
ipv6.ignore-auto-routes:    no 
ipv6.ignore-auto-dns:     no 
ipv6.never-default:      no 
ipv6.may-fail:       yes 
ipv6.ip6-privacy:      -1 (unknown) 
ipv6.addr-gen-mode:      stable-privacy 
ipv6.dhcp-send-hostname:    yes 
ipv6.dhcp-hostname:      -- 

gsm.number:        *99# 
gsm.username:       <hidden> 
gsm.password:       <hidden> 
gsm.password-flags:      0 (none) 
gsm.apn:        myapn.com 
gsm.network-id:       -- 
gsm.pin:        <hidden> 
gsm.pin-flags:       0 (none) 
gsm.home-only:       no 
gsm.device-id:       -- 
gsm.sim-id:        -- 
gsm.sim-operator-id:     -- 

我的問題是如何啓用不可用的設備,爲什麼它不可用?我可以檢查什麼來幫助我解決問題。

任何幫助將是偉大的,因爲我只是開始在Snappy。

+0

應該補充我使用戴爾網關3002運行Ubuntu核心 – Bart

回答

0

好了,所以我設法解決我自己的問題,是我所採取的步驟如下:

1)檢查我的網關調制解調器被Ubuntu核心閱讀:

$ sudo mmcli -L 

Found 1 modems: 
    /org/freedesktop/ModemManager1/Modem/0 [Generic] MBIM [1519:0020] 

2 )檢查SIM卡正確讀取:

$ sudo mmcli -m 0 

/org/freedesktop/ModemManager1/Modem/0 (device id 'd8b328efa783ca35a022d6b44b878981e67a5903') 
    ------------------------- 
    Hardware | manufacturer: 'Generic' 
      |   model: 'MBIM [1519:0020]' 
      |  revision: 'MOD_6260_V05.1412.00_R07_VCTCX' 
      |  supported: 'gsm-umts' 
      |  current: 'gsm-umts' 
      | equipment id: '014752000020933' 
    ------------------------- 
    System |   device: '/sys/devices/pci0000:00/0000:00:14.0/usb1/1-3' 
      |  drivers: 'cdc_acm, cdc_mbim' 
      |   plugin: 'Generic' 
      | primary port: 'cdc-wdm0' 
      |   ports: 'cdc-wdm0 (mbim), wwan0 (net), ttyACM0 (at)' 
    ------------------------- 
    Numbers |   own : 'unknown' 
    ------------------------- 
    Status |   lock: 'none' 
      | unlock retries: 'sim-pin (3)' 
      |   state: 'connected' 
      | power state: 'on' 
      | access tech: 'gprs' 
      | signal quality: '67' (cached) 
    ------------------------- 
    Modes |  supported: 'allowed: 2g, 3g; preferred: none' 
      |  current: 'allowed: 2g, 3g; preferred: none' 
    ------------------------- 
    Bands |  supported: 'unknown' 
      |  current: 'unknown' 
    ------------------------- 
    IP  |  supported: 'ipv4, ipv6, ipv4v6' 
    ------------------------- 
    3GPP  |   imei: '<censored>' 
      | enabled locks: 'fixed-dialing' 
      | operator id: '27203' 
      | operator name: 'IRL - METEOR' 
      | subscription: 'unknown' 
      | registration: 'home' 
    ------------------------- 
    SIM  |   path: '/org/freedesktop/ModemManager1/SIM/0' 

    ------------------------- 
    Bearers |   paths: '/org/freedesktop/ModemManager1/Bearer/0' 

這是我意識到,我的SIM尚未在網關發現,我有一個損壞SIM卡,我已經改變了我的SIM卡,並與輸出想出了ABOV即

3)配置新的APN或編輯現有的APN。 (我發現它更容易添加重新連接)

確保您在根(sudo su -

一)刪除是失敗

#nmcli con delete MyConnection 

b現有連接)創建新的連接

#nmcli con add type gsm ifname cdc-wdm0 con-name MyWorkingConnection apn MyNewApn.com 

4)添加用戶名和密碼,以新的連接

#nmcli con edit MyWorkingConnection 

此時您將處於nmcli>提示符狀態。請輸入幫助以獲取幫助您編輯連接的命令列表。對我來說,我需要添加用戶名和密碼,所以我實現了通過鍵入:

nmcli> set gsm.username data 
nmcli> set gsm.password <passwordgoeshere> 
nmcli> save 
nmcli> quit 

在這一點上我的連接已經建立。我已經找到了命令

#nmcli m 

在另一個會議是檢查接口變化的狀態有用的開放。

希望這可以幫助一些人!