On Thu, Jan 23, 2014 at 8:55 PM, Mansour Al Akeel
<mansour.alak...@gmail.com> wrote:
> Canek,
> Thank you. The output is attached.
>
>
> On Thu, Jan 23, 2014 at 8:10 PM, Canek Peláez Valdés <can...@gmail.com> wrote:
>> On Thu, Jan 23, 2014 at 6:56 PM, Mansour Al Akeel
>> <mansour.alak...@gmail.com> wrote:
>>> Hello all,
>>>
>>> I installed gnome3 few weeks ago, and had to migrate to systemd.
>>> The network init scripts are working fine. But I am not sure how to
>>> restart a specific interface.
>>> For example in the past I used to do:
>>>
>>> /etc/init.d/net.eth0 restart
>>>
>>> The wlan0 starts through wpa_supplicant under openrc.
>>>
>>> I can not remember doing any modification to adopt to systemd. The
>>> wpa_supplicant is not running under systemd, but wlan0 is working:
>>>
>>> neptune ~ # systemctl status wpa_supplicant
>>> wpa_supplicant.service - WPA supplicant
>>>    Loaded: loaded (/usr/lib/systemd/system/wpa_supplicant.service; disabled)
>>>    Active: inactive (dead)
>>>
>>> Jan 23 19:54:20 neptune systemd[1]: Collecting wpa_supplicant.service
>>>
>>>
>>>
>>> I think it's because of dhcpcd, but not sure.
>>> my question now, is how to stop wlan0 and start eth0 with systemd ??
>>
>> Are you still using the unpredictable network interface names[1]? Are
>> you using net.ifnames=0 in your kernel command line?
>>
>> Could you please post the whole output of "systemctl --full --all"? We
>> need to know what services you have enabled.
>>
>> Regards.
>>
>> [1] 
>> http://www.freedesktop.org/wiki/Software/systemd/PredictableNetworkInterfaceNames/

Please don't top post.

Here is the answer:

wpa_supplicant@wlan0.service
                                          loaded active   running
WPA supplicant daemon (interface-specific version)

wpa_supplicant offers a template unit, wpa_supplicant@.service. From
man:systemd.unit(1)

"Optionally, units may be instantiated from a template file at
runtime. This allows creation of multiple units from a single
configuration file. If systemd looks for a unit configuration file, it
will first search for the literal unit name in the filesystem. If that
yields no success and the unit name contains an "@" character, systemd
will look for a unit template that shares the same name but with the
instance string (i.e. the part between the "@" character and the
suffix) removed. Example: if a service getty@tty3.service is requested
and no file by that name is found, systemd will look for
getty@.service and instantiate a service from that configuration file
if it is found."

Something is starting wpa_supplicant@wlan0.service. Could you run:

systemctl list-dependencies --reverse wpa_supplicant@wlan0.service

That will tell you what is pulling wpa_supplicant@wlan0.service. Also,
the following:

systemctl is-enabled wpa_supplicant@wlan0.service

will tell you if the unit is enabled or not.

Regards.
-- 
Canek Peláez Valdés
Posgrado en Ciencia e Ingeniería de la Computación
Universidad Nacional Autónoma de México

Reply via email to