You are not logged in.

#1 2015-12-07 17:25:11

hatahata50
Banned
Registered: 2014-11-29
Posts: 47
Website

[SOLVED] wifi dhcpcd ( when key is short) & wifi netctl

hi all .

as usual user , arch's top level difficulty is to connect intarnet  in case that wifi-menu  fails .
so i try manual setting of wifi .

i stay in a hotel .
there passphrase is too short only 5 characters 'tatum'.

# wpa_passphrase tatumi3F tatum
Passphrase must be 8..63 characters

then i rewrite wpa_supplicant setting (rtl8192cu & arch 32bit)

[root@dell yuma]# cat /TATUMI 
-------------------------------------------------
ctrl_interface=/var/run/wpa_supplicant
update_config=1


network={
	ssid="tatumi3F"
	key_mgmt=NONE
	wep_key0="tatum" 
	priority=5
}


network={
	ssid="tatumi2F"
	key_mgmt=NONE
	wep_key0="tatum"
	priority=9
}



[root@dell yuma]# ./comment-out.bat wifi.bat-tatumi  #<---connecting  shell script is
---------------------------------------------------------------------- 
systemctl disable systemd-networkd.service
rm /run/wpa_supplicant/wlp0s29f7u3
rm /run/wpa_supplicant/wlp0s29f7u4
x=wlp0s29f7u3
   ip link set $x  up
   wpa_supplicant -B -D nl80211 -c /TATUMI -i $x
dhcpcd -A $x  # <----------------------------------------------attension
sleep 10
echo '----------------------------'
ping -c 3 www.google.com
ifconfig | grep 192


----------------------------------------->
 ./wifi.bat-tatumi 
rm: `/run/wpa_supplicant/wlp0s29f7u3' を削除できません: そのようなファイルやディレクトリはありません
rm: `/run/wpa_supplicant/wlp0s29f7u4' を削除できません: そのようなファイルやディレクトリはありません
Successfully initialized wpa_supplicant
wlp0s29f7u3: waiting for carrier
wlp0s29f7u3: carrier acquired
wlp0s29f7u3: adding address fe80::8037:d6ed:6364:efba
DUID 00:01:00:01:1d:c0:62:e6:00:1e:c9:05:78:fc
wlp0s29f7u3: IAID cf:ec:c8:05
wlp0s29f7u3: soliciting an IPv6 router
wlp0s29f7u3: rebinding lease of 192.168.1.4
wlp0s29f7u3: leased 192.168.1.4 for 14400 seconds
wlp0s29f7u3: adding route to 192.168.1.0/24
wlp0s29f7u3: adding default route via 192.168.1.1
forked to background, child pid 603
----------------------------
PING www.google.com (216.58.221.196) 56(84) bytes of data.
64 bytes from kix03s02-in-f4.1e100.net (216.58.221.196): icmp_seq=2 ttl=51 time=28.2 ms

--- www.google.com ping statistics ---
3 packets transmitted, 1 received, 66% packet loss, time 2000ms
rtt min/avg/max/mdev = 28.274/28.274/28.274/0.000 ms
        inet 192.168.1.4  netmask 255.255.255.0  broadcast 192.168.1.255
---------------------------------<




[root@dell yuma]#  systemctl list-unit-files|grep enabled #<---now state
--------------------------------------------------------------------------
autovt@.service                            enabled 
dhcpcd@.service                            enabled 
display-manager.service                    enabled 
getty@.service                             enabled 
lxdm.service                               enabled 
openntpd.service                           enabled 
remote-fs.target                           enabled

i was suggestted to use not dhspcd  but to use netcl .
then connecing shell script should to be rewitten , but i do not know how to .
are there any suggestion ?


and
normal key is enough long (for example:psk=002f9520d102f21236fb169e7a56925fae513d1f211414f59e8f1133fad38637)
wep_key0 is short , so i guss that wifi security is weak .
is this true ?

---------
(ps)
after this , wired is not connected automaticall .
so i need shell script.

wired.bat 
------------------------------------
x=enp9s0
dhcpcd -A $x

echo '----------------------------'
ping -c 3 www.google.com

Last edited by hatahata50 (2015-12-08 22:55:31)

Offline

#2 2015-12-08 06:55:00

hatahata50
Banned
Registered: 2014-11-29
Posts: 47
Website

Re: [SOLVED] wifi dhcpcd ( when key is short) & wifi netctl

i try  netctl instead of  dhcpcd .
but this is hard to understand because of arch linux specificity .

i am reading  https://wiki.archlinux.org/index.php/Netctl now.

Last edited by hatahata50 (2015-12-08 17:57:48)

Offline

#3 2015-12-08 11:12:41

hatahata50
Banned
Registered: 2014-11-29
Posts: 47
Website

Re: [SOLVED] wifi dhcpcd ( when key is short) & wifi netctl

at last  i can succeed in netctl  .

all is written in https://wiki.archlinux.org/index.php/Netctl .

A) remove wifi USB   and plugi wired LAN , then reboot PC , it connect to internet
B) remove wired LAN and plug in wifi USB , then reboot PC , it connect to internet

the result is OK , but  i forget orders to setup.




1) dhcpcd and netctl conflict each other

systemctl disable dhcpcd
pacman -S netctl

now

systemctl list-unit-files|grep enabled
autovt@.service                            enabled 
display-manager.service                    enabled 
getty@.service                             enabled 
lxdm.service                               enabled 
netctl-auto@.service                       enabled 
netctl.service                             enabled 
openntpd.service                           enabled 
sshd.service                               enabled 
remote-fs.target                           enabled

2)

ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp2s0: <BROADCAST,MULTICAST> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000
    link/ether f0:76:1c:6c:41:af brd ff:ff:ff:ff:ff:ff
3: wlp3s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000 #<-------------------------no driver
    link/ether d0:53:49:6f:a1:d8 brd ff:ff:ff:ff:ff:ff
4: wlp0s20u2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DORMANT group default qlen 1000#<------use this
    link/ether 00:22:cf:01:22:6f brd ff:ff:ff:ff:ff:ff

3)

wifi-menu -o wlp0s20u2

4)


i might do other things .
for example
pacman -Sy wpa_actiond
pacman -Sy ifplug
# systemctl enable netctl-auto@interface.service
# systemctl enable netctl-ifplugd@interface.service
netctl enable wlp0s20u2-URoad-9BF5EC
netctl enable enp2s0-dhcp

i report only now states .

[root@lnv tuyosi]# cat /etc/netctl/enp2s0-dhcp #<------wired
Description='A basic dhcp ethernet connection'
Interface=enp2s0
Connection=ethernet
IP=dhcp


[root@lnv tuyosi]# cat /etc/netctl/wlp0s20u2-URoad-9BF5EC #<---------wifi
Description='Automatically generated profile by wifi-menu'
Interface=wlp0s20u2
Connection=wireless
Security=wpa
ESSID=URoad-9BF5EC
IP=dhcp
Key=\"33948dd44dd3f20bfc023b1a7e8a4479fab69744a79192677c



[root@lnv tuyosi]# pacman -Q| grep ifplugd
[root@lnv tuyosi]# pacman -Q| grep wpa_actiond
wpa_actiond 1.4-2

this report needs trials to make  stable  how to netctl .

-----------------------
PS
A) i am poor english speaker , so i write down in Japanese at http://hatahata50.blogspot.jp/2015/12/wifi-netctl.html

B) later i cloned arch in sda2 to sdb7


./comment-out.bat /Arch-backup-sda2-2-sdb7.bat

 
 y='/mnt/sda2'
z='/mnt/sdb7'
df
echo $y '---->' $z
mkdir -p $z
read X
echo $X
cd $y
for x in bin boot cdrom dev etc grldr home initrd.img lib lib64 media opt proc root run sbin srv sys tmp usr var vmlinuz
do
echo $x
 (cd $y  ; tar cvpf - $x )|( cd $z ; tar xpf - )
done
cp -pR  $y/initrd.img $z
cp -pR  $y/vmlinuz $z

and i do all the followings

pacman -Sy wpa_actiond
pacman -Sy ifplugd


# systemctl enable netctl-auto@interface.service 
# systemctl enable netctl-ifplugd@interface.service 

 netctl enable wlp0s20u2-URoad-9BF5EC
 netctl enable enp2s0-dhcp

it(sdb7)  works.

change wied to wifi

netctl stop enp2s0-dhcp
netctl restart wlp0s20u1-URoad-9BF5EC;

Last edited by hatahata50 (2015-12-08 22:53:08)

Offline

Board footer

Powered by FluxBB