New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When enabling profiles with a dash, systemd encodes it as x2d and netctl fails to find profile #66

Closed
kaihendry opened this Issue Nov 13, 2013 · 10 comments

Comments

Projects
None yet
3 participants
@kaihendry

kaihendry commented Nov 13, 2013

Full log: http://sprunge.us/OSfj

Nov 13 12:00:40 pihsg network[869]: Profile 'wlan0x2dKGBFREE' does not exist or is not readable
Nov 13 12:00:40 pihsg systemd[1]: netctl@wlan0x2dKGBFREE.service: main process exited, code=exited, status=1/FAILURE
@joukewitteveen

This comment has been minimized.

Show comment
Hide comment
@joukewitteveen

joukewitteveen Nov 14, 2013

Owner

Don't blame netctl for your own faults:

# systemctl start netctl@wlan0\x2dKGBFREE.service

This line causes the output you report as a bug. The argument contains a /, hence it needs to be quoted/escaped. On top of that, this is not the right way to use netctl, but you seem to know that. Instead of the above command, you needed:

netctl start wlan0-KGBFREE

Quoting and escaping for systemd is handled by netctl.

Owner

joukewitteveen commented Nov 14, 2013

Don't blame netctl for your own faults:

# systemctl start netctl@wlan0\x2dKGBFREE.service

This line causes the output you report as a bug. The argument contains a /, hence it needs to be quoted/escaped. On top of that, this is not the right way to use netctl, but you seem to know that. Instead of the above command, you needed:

netctl start wlan0-KGBFREE

Quoting and escaping for systemd is handled by netctl.

@kaihendry

This comment has been minimized.

Show comment
Hide comment
@kaihendry

kaihendry Nov 14, 2013

No, the problem is when I ran:

netctl start 'wlan0-Mac4 - Weilun'
Job for netctl@wlan0\x2dMac4\x20\x2d\x20Weilun.service failed. See 'systemctl status netctl@wlan0\x2dMac4\x20\x2d\x20Weilun.service' and 'journalctl -xn' for details.

I then renamed it to get workaround this.

kaihendry commented Nov 14, 2013

No, the problem is when I ran:

netctl start 'wlan0-Mac4 - Weilun'
Job for netctl@wlan0\x2dMac4\x20\x2d\x20Weilun.service failed. See 'systemctl status netctl@wlan0\x2dMac4\x20\x2d\x20Weilun.service' and 'journalctl -xn' for details.

I then renamed it to get workaround this.

@joukewitteveen

This comment has been minimized.

Show comment
Hide comment
@joukewitteveen

joukewitteveen Nov 14, 2013

Owner

No, you did not. The renaming was not needed. You can use netctl status <your-profile> as a shorthand for systemctl status netctl@<your-profile-but-escaped>.service.

Owner

joukewitteveen commented Nov 14, 2013

No, you did not. The renaming was not needed. You can use netctl status <your-profile> as a shorthand for systemctl status netctl@<your-profile-but-escaped>.service.

@kaihendry

This comment has been minimized.

Show comment
Hide comment
@kaihendry

kaihendry Nov 18, 2013

Ok, most people would probably stick to using systemctl like they do with the rest of their system and run into this issue again and again.

kaihendry commented Nov 18, 2013

Ok, most people would probably stick to using systemctl like they do with the rest of their system and run into this issue again and again.

@WurdahMekanik

This comment has been minimized.

Show comment
Hide comment
@WurdahMekanik

WurdahMekanik Nov 18, 2013

I agree... It's a little counter intuitive to have a program designed to
act like systemd not play nice with systemd. I've run into this problem
often as well.
On Nov 17, 2013 6:37 PM, "Kai Hendry" notifications@github.com wrote:

Ok, most people would probably stick to using systemctl like they do with
the rest of their system and run into this issue again and again.


Reply to this email directly or view it on GitHubhttps://github.com/joukewitteveen/netctl/issues/66#issuecomment-28668950
.

WurdahMekanik commented Nov 18, 2013

I agree... It's a little counter intuitive to have a program designed to
act like systemd not play nice with systemd. I've run into this problem
often as well.
On Nov 17, 2013 6:37 PM, "Kai Hendry" notifications@github.com wrote:

Ok, most people would probably stick to using systemctl like they do with
the rest of their system and run into this issue again and again.


Reply to this email directly or view it on GitHubhttps://github.com/joukewitteveen/netctl/issues/66#issuecomment-28668950
.

@joukewitteveen

This comment has been minimized.

Show comment
Hide comment
@joukewitteveen

joukewitteveen Nov 18, 2013

Owner

If you don't understand systemd escaping, you don't understand systemd.

Owner

joukewitteveen commented Nov 18, 2013

If you don't understand systemd escaping, you don't understand systemd.

@WurdahMekanik

This comment has been minimized.

Show comment
Hide comment
@WurdahMekanik

WurdahMekanik Nov 18, 2013

So even when generating profiles through wifi-menu or netctl procedures and
then using systemctl enable/start netctl-auto@[wireless-device] and seeing
similar errors upon startup, that is still somehow me failing to escape
systemd properly?
On Nov 18, 2013 4:31 AM, "Jouke Witteveen" notifications@github.com wrote:

If you don't understand systemd escaping, you don't understand systemd.


Reply to this email directly or view it on GitHubhttps://github.com/joukewitteveen/netctl/issues/66#issuecomment-28687835
.

WurdahMekanik commented Nov 18, 2013

So even when generating profiles through wifi-menu or netctl procedures and
then using systemctl enable/start netctl-auto@[wireless-device] and seeing
similar errors upon startup, that is still somehow me failing to escape
systemd properly?
On Nov 18, 2013 4:31 AM, "Jouke Witteveen" notifications@github.com wrote:

If you don't understand systemd escaping, you don't understand systemd.


Reply to this email directly or view it on GitHubhttps://github.com/joukewitteveen/netctl/issues/66#issuecomment-28687835
.

@joukewitteveen

This comment has been minimized.

Show comment
Hide comment
@joukewitteveen

joukewitteveen Nov 18, 2013

Owner

Yes, indeed.

Owner

joukewitteveen commented Nov 18, 2013

Yes, indeed.

@WurdahMekanik

This comment has been minimized.

Show comment
Hide comment
@WurdahMekanik

WurdahMekanik Nov 18, 2013

So you're saying that even when I type in something with no hyphens such
as:

systemctl enable/start netctl-auto@wlp3s0.service

I'm somehow failing to escape something when systemd attempts to switch
profiles automatically for me? Profile renaming helps, as does connecting
manually in either way you describe, yet I can't seem to get systemd to
switch automatically.

Now this may actually not even be an issue with naming and could be
something else, but the errors aren't very forthcoming so at the moment it
seems like I'll have to stick to my current procedure of manually
connecting all the time until I find the problem.
On Nov 18, 2013 7:23 AM, "Jouke Witteveen" notifications@github.com wrote:

Yes, indeed.


Reply to this email directly or view it on GitHubhttps://github.com/joukewitteveen/netctl/issues/66#issuecomment-28697143
.

WurdahMekanik commented Nov 18, 2013

So you're saying that even when I type in something with no hyphens such
as:

systemctl enable/start netctl-auto@wlp3s0.service

I'm somehow failing to escape something when systemd attempts to switch
profiles automatically for me? Profile renaming helps, as does connecting
manually in either way you describe, yet I can't seem to get systemd to
switch automatically.

Now this may actually not even be an issue with naming and could be
something else, but the errors aren't very forthcoming so at the moment it
seems like I'll have to stick to my current procedure of manually
connecting all the time until I find the problem.
On Nov 18, 2013 7:23 AM, "Jouke Witteveen" notifications@github.com wrote:

Yes, indeed.


Reply to this email directly or view it on GitHubhttps://github.com/joukewitteveen/netctl/issues/66#issuecomment-28697143
.

@joukewitteveen

This comment has been minimized.

Show comment
Hide comment
@joukewitteveen

joukewitteveen Nov 18, 2013

Owner

systemctl <enable|start> netctl-auto@wlp3s0.service is the proper way to use netctl-auto and documented as such in netctl.special(7). No problem there. I will not reply to this thread anymore, as there is no actual issue that is being discussed.

Owner

joukewitteveen commented Nov 18, 2013

systemctl <enable|start> netctl-auto@wlp3s0.service is the proper way to use netctl-auto and documented as such in netctl.special(7). No problem there. I will not reply to this thread anymore, as there is no actual issue that is being discussed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment