You are not logged in.

#1 2012-11-05 21:59:39

fulmare
Member
Registered: 2011-02-16
Posts: 25

[SOLVED]loginctl gives me Active=no

I've checked the wiki of course, but it has not worked, here is my /etc/xserververrc:

#! /bin/sh
if [[ -z $XDG_VTNR ]]; then
exec /usr/bin/X -nolisten tcp "$@"
else
exec /usr/bin/X -nolisten tcp "$@" vt$XDG_VTNR
fi

the alias I use to start from tty1:

[[ -z $DISPLAY && $XDG_VTNR -eq 1 ]] && xinit ~/.config/xinitrc/openboxxinitrc -- &

Systemd gives no erros at boot.
Could you give me a clue?

Last edited by fulmare (2012-11-06 16:10:39)

Offline

#2 2012-11-06 00:28:44

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,414

Re: [SOLVED]loginctl gives me Active=no

I am totally unsure about this, but what happens if you remove the '--' from the xinit command?

Also, is your system totally up to date, and are you booting with systemd?

Offline

#3 2012-11-06 02:50:27

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,130

Re: [SOLVED]loginctl gives me Active=no

What's in ~/.config/xinitrc/openboxxinitrc?

Does ~/.xserverrc exist?

Is it really /etc/xserververrc? If so, should it be /etc/xserverrc?


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#4 2012-11-06 14:05:40

fulmare
Member
Registered: 2011-02-16
Posts: 25

Re: [SOLVED]loginctl gives me Active=no

Thank you anyone
@WonderWoofy
"--" removed, nothing changes. It was supposed to launch X on alternate tty.
Everything is up to date, I'm booting with pure systemd (no init argument to kernel line).

@cfr
I've no ~/.xserverrc, here it's ~/.config/xinitrc/openboxxinitrc

if [ -d /etc/X11/xinit/xinitrc.d ]; then
  for f in /etc/X11/xinit/xinitrc.d/*; do
    [ -x "$f" ] && . "$f"
  done
  unset f
fi
exec openbox-session

Sorry, I mean /etc/X11/xinit/xserverrc
This is my /etc/systemd/logind.conf :
[Login]
HandlePowerKey=
HandleSuspendKey=
HandleHibernateKey=
HandleLidSwitch=

Last edited by fulmare (2012-11-06 14:45:44)

Offline

#5 2012-11-06 15:00:16

decaturguy
Member
From: Sweden
Registered: 2006-11-28
Posts: 117

Re: [SOLVED]loginctl gives me Active=no

I used to have same problem with Gnome and it required  authentication to mount external drive and to power off and reboot.
The problem was rc-local.service. https://bbs.archlinux.org/viewtopic.php?id=152057

Offline

#6 2012-11-06 15:12:24

65kid
Member
From: Germany
Registered: 2011-01-26
Posts: 663

Re: [SOLVED]loginctl gives me Active=no

don't use xinit, put "exec openbox-session" in your ~/.xinitrc and start X with "startx". Make sure you use the .xinitrc from /etc/skel/ which contains the /etc/X11/xinit/xinitrc.d/* loop which is needed to autostart dbus.

Offline

#7 2012-11-06 15:39:48

fulmare
Member
Registered: 2011-02-16
Posts: 25

Re: [SOLVED]loginctl gives me Active=no

@decaturguy
I've not a rc-local.service in the filesystem.
@65kid
So my ~/.xinitrc is

#!/bin/sh
#
# ~/.xinitrc
#
# Executed by startx (run your window manager from here)

if [ -d /etc/X11/xinit/xinitrc.d ]; then
  for f in /etc/X11/xinit/xinitrc.d/*; do
    [ -x "$f" ] && . "$f"
  done
  unset f
fi
exec openbox-session

If I use xinit the problem continues.
If I use startx, X server does not start, it says.

xf86OpenConsole: VT_ACTIVATE failed: Operation not permitted

I'm googleing the error without success.

Offline

#8 2012-11-06 15:49:26

65kid
Member
From: Germany
Registered: 2011-01-26
Posts: 663

Re: [SOLVED]loginctl gives me Active=no

this should work, not sure what you screwed up there. Reinstall xorg-server and xorg-xinit. Also log into tty1 as your normal user and check if the following contains Active=yes:

loginctl show-session $XDG_VTNR

Offline

#9 2012-11-06 16:09:59

fulmare
Member
Registered: 2011-02-16
Posts: 25

Re: [SOLVED]loginctl gives me Active=no

Good, it seems solved using startx and xorg-server and xorg-xinit reinstallation (xinit still doesn't work). Not sure what went wrong but now it works! Thank you very much 65kid.

Offline

#10 2013-11-20 22:06:25

lupus
Member
Registered: 2013-11-20
Posts: 1

Re: [SOLVED]loginctl gives me Active=no

I hope it's ok that I bump this thread, since I found an explanation to why startx works and xinit doesnt. I had the same problem with xinit myself, but I found the following post which also explains why it works with startx:
http://blog.falconindy.com/articles/bac … stemd.html
So for instance if I use:

xinit [window manager] -- vt01

I now get an active session.

Offline

#11 2019-03-08 05:38:51

bilabila
Member
Registered: 2018-08-07
Posts: 23
Website

Re: [SOLVED]loginctl gives me Active=no

vt1 is the trick
startx add "vt1 -keeptty" to xinit by default

    # When starting the defaultserver start X on the current tty to avoid
    # the startx session being seen as inactive:
    # "https://bugzilla.redhat.com/show_bug.cgi?id=806491"
    tty=$(tty)
    if expr "$tty" : '/dev/tty[0-9][0-9]*$' > /dev/null; then
        tty_num=$(echo "$tty" | grep -oE '[0-9]+$')
        vtarg="vt$tty_num -keeptty"
    fi

but if using alternative xserverrc, manually add vt1 is required

exec startx $XINITRC -- $XSERVERRC vt1 -keeptty

otherwise the Active property will be no, and cause permission issue

Offline

#12 2019-03-08 06:16:10

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: [SOLVED]loginctl gives me Active=no

Six year old solved thread: don't do that. https://wiki.archlinux.org/index.php/Co … bumping.22



Closing


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

Board footer

Powered by FluxBB