alias startx='xinit -- /usr/bin/X -nolisten tcp vt1 &> ~/.xlog'
this will start X on 1st tty.
and if you want to start X automatically . Here is my .bash_profile
if [[ -z $DISPLAY ]] && ! [[ -e /tmp/.X11-unix/X0 ]] && (( EUID )); then
while true; do
read -p 'Do you want to start X? (y/n): '
case $REPLY in
[Yy]) exec xinit -- /usr/bin/X -nolisten tcp vt1 &> ~/.xlog ;;
[Nn]) break ;;
*) printf '%s\n' 'Please answer y or n.' ;;
esac
done
fi
Just for a note : I have 'ck-launch-session' in my xinitrc.
EDIT: Sorry I did not see that this thread is little bit old. But since the issue was not solved , I thought that this workaround would prove helpful to someone.
]]>we don't get a consolekit session, only a logind one. That would be fine if all our stuff (polkit, networkamnager, ...) was compiled with logind support rather than consolekit. However, it is not...
In .xinitrc I have
ck-launch-session startxfce4
Doesn't this launch the consolekit session as well?
]]>Edit: It works! Turns out there was an FS problem with the USB drive I was testing with. Using the packages below, everything works just fine. No need for slim or any other DM
Here's the user session unit running:
http://i.imgur.com/8LEP4.png
----------------------------------
Original post:
It works! Sort of...Using dbus-core-systemd-users-sessions and systemd-user-session-units from AUR I get the following:
$ loginctl show-session 1 | grep Active Active=yes
Automount works (though it worked prior to this as well) but permissions are still not correct. Assuming my username is "foo", it gets automounted with:
dr-x------ foo users
So I still can't write to the device. Now what?
I had another look at this. It seems to me that the remaining issue is that when using the user session, we don't get a consolekit session, only a logind one. That would be fine if all our stuff (polkit, networkamnager, ...) was compiled with logind support rather than consolekit. However, it is not...
]]>Here's the user session unit running:
----------------------------------
Original post:
It works! Sort of...
Using dbus-core-systemd-users-sessions and systemd-user-session-units from AUR I get the following:
$ loginctl show-session 1 | grep Active
Active=yes
Automount works (though it worked prior to this as well) but permissions are still not correct. Assuming my username is "foo", it gets automounted with:
dr-x------ foo users
So I still can't write to the device. Now what?
]]>In any case, I'll test this configuration later today and see if I can make it work without a DM.
]]>I'm having the same problem as @Angeldeath. Would this help in this situation? It sounds like running
systemctl enable user-session@joe.service
with this unit set installed would remove the requirement for a DM. Thoughts?
Eventually it should, yes. However, this stuff is still under active (early) development, and will likely not work out-of-the-box. As far as I know some patches are needed to dbus, and maybe other things.
]]>systemctl enable user-session@joe.service
with this unit set installed would remove the requirement for a DM. Thoughts?
]]>And the permission issue is solved, (although I don't like the solution, since I don't want to use a desktop manager, and it uses extra space) just the automount on insert and changing discs is still present.
But thanks to all who tried to help me till now!
Now I just need someone who and help me get automount to work and the best would be an udev rule. (I don't have any knowledge in writing those...)
PCMANFM
sudo nano ~/.xinitrc
exec startfluxbox
slim
/etc/inittab
#id:3:initdefault:
id:5:initdefault:
#x:5:respawn:/usr/bin/slim >/dev/null 2>&1
/etc/slim.conf
login_cmd exec dbus-launch /bin/bash -login ~/.xinitrc %session
Note: slim is ConsoleKit capable since version 1.3.3. Unless you happen to run an old version, you must no longer include ck-launch-session in your .xinitrc or slim.conf login_cmd. You should still have dbus-launch in your login_cmd, see #SLiM_and_Gnome_Keyring, since this gives subprocesses of your session the correct permissions (e.g. to mount something with gvfs-mount, like Pcmanfm does).
]]>By adding the pam_systemd stuff to login that's why you have the one session you do have. You need xinit to also hook into pam to create a second session (as I said I don't know how to do this without a DE).
]]>Btw.: also tried this: https://wiki.archlinux.org/index.php/Sy … r_sessions
And added the necessary parts to "login" <- Is that what's meant to get it to work without an desktop manager?
I will try to get a very slick desktop manager installed, in hope it fixes at least one issue...
]]>I guess what happens is that if you do "loginctl show-session 1 | grep Active" from tty1 (the console) you get "yes", but from tty2 (the graphical one) you get "no". The reason is that no new session was opened as you called xinit directly.
In the future what you'll want is to use the systemd user session bus and this should work nicely. However, that is not ready yet, and I don't know how to get graphical sessions working without some form of desktop manager (I have lost track of which ones are supported, but I think they all should be).
]]>