Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
systemd questions (Fresh Install)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Gloom_Scythe
n00b
n00b


Joined: 01 Sep 2014
Posts: 12

PostPosted: Tue Jul 14, 2015 6:42 pm    Post subject: systemd questions (Fresh Install) Reply with quote

Hello,

I am installing gentoo from scratch and this will be my first time setting up/using systemd on a fresh install. (had to wipe my gentoo partition because the system became broken from trying to upgrade to systemd.) I was having a hard time trying to find a WM I liked that was still supported with openrc. Is initramfs required in order to boot to gentoo with systemd ( read the following from the systemd document: "For a split /usr configuration, use an initramfs to mount /usr before starting systemd." What do you guys mean by split /usr?)? (I do not use genkernel). I do have a UEFI system but I dont intend on using the UEFI. (I set my bios to act more like legacy bios instead of UEFI for security reasons) I am not to familiar with UUIDs. Would it be advisable to use UUIDs in the bootloader? I apologize for the newbie questions. I have an amd 9370 8 core. Is there any recommended cflags I should use for this processor that https://wiki.gentoo.org/wiki/Safe_CFLAGS#FX-XXXX does not mention? I was upset about systemd at one time but I got over it. I guess I have to learn to live with it now hehe.

Is there anything you guys would suggest to watch out for during the install from scratch with systemd? Wish I could avoid systemd all together. I apologize for my previous negative posts about gentoo and systemd.

Thank you for the help :)
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7132
Location: almost Mile High in the USA

PostPosted: Tue Jul 14, 2015 7:37 pm    Post subject: Reply with quote

I found the Gentoo systemd guide fairly good, it seemed to work for me when I migrated (with some hiccups).
But what WM (or rather, DE) are you trying to use? They should be fairly disjoint unless you want Gnome3 which seems to have some functionality depending on systemd. I think most DEs still support consolekit/policykit (or you can just do away with them) so they can be run fine under OpenRC.

When it says split /usr, it means if you have /usr in a separate partition you need to follow special instructions. Many desktop users have /usr in the same partition as your root partition, so this doesn't always apply. If you do have /usr in its own partition you will need to use an initramfs to mount /usr before systemd starts up.

UUIDs are only needed if your boot disk changes from /dev/sda to /dev/sdb or something and can't predict it. This tells Linux to look for specific disks instead of a connection point.
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
Gloom_Scythe
n00b
n00b


Joined: 01 Sep 2014
Posts: 12

PostPosted: Tue Jul 14, 2015 8:02 pm    Post subject: Reply with quote

I was planning on using gnome. So I can use gnome with openrc if I remove policykit/consolekit? I like fluxbox too but setting up the menus is a pain. I was under the impression it was impossible to run gnome without systemd. Is there a guide you can reference? Well I use gentoo on a second ssd dedicated for gentoo.... Do I still need to use UUIDs? I usually install the bootloader on the first harddrive containing win7 (for the moment). I have only used gnome, kde, and fluxbox. I am not a big fan of kde. Are there any DE's you would recommend I try? There are quite a few I see.


Thank you for the input.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43192
Location: 56N 3W

PostPosted: Tue Jul 14, 2015 9:17 pm    Post subject: Reply with quote

Gloom_Scythe,

I gave up Gnome3 for Xfce4 rather than have systemd,
Only Gnome3 currently depends on systemd.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7132
Location: almost Mile High in the USA

PostPosted: Tue Jul 14, 2015 11:55 pm    Post subject: Reply with quote

If you randomly notice your /dev/sdXX changing from boot to boot, like if you insert USB drives or you swap drives out frequently, having UUID support is very helpful. If you have a static system, then it's not absolutely necessary. I use it to reduce the annoyance when I swap disks around my multiple machines.

Consolekit/Polkit is the "old" way of dealing with console-granted privileges. These can be used with OpenRC. If you don't need console-granted privileges (like automount USB disks, access to sound card only for whoever logs in, shutdown/reboot by console user, etc.) then you can try removing them as many DEs you can disable them via USE (granted, I think it gimps the DE, and might well not bother with the DE). Systemd handles what consolekit/polkit does, so they need not be installed separately.

As NeddySeagoon says, Gnome3 now has systemd stuff built in. I think it's specifically gdm that has dependencies on systemd but not totally sure; my Gnome3 machines are running systemd. All of my other machines run xfce4 with OpenRC and provide a comparable user experience. I do have one systemd machine running xfce4 because ati-drivers chokes on gdm/systemd at the moment (and gnome3 doesn't work anymore)... Talk about a silly workaround...
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
davidm
Guru
Guru


Joined: 26 Apr 2009
Posts: 557
Location: US

PostPosted: Wed Jul 15, 2015 12:52 am    Post subject: Reply with quote

As with eccerr0r I recently switched to systemd (while using KDE plasma 5) and found it to go well as long as I read all (make sure to read the whole thing once before starting) the instructions on the gentoo systemd wiki page.

Generally I just built the kernel first to be systemd compatible then before rebooting I continued with the necessary steps including changing my use flags, updating world as instructed, and then changing any configs I could without rebooting and also making sure to configure my bootloader (Which was grub2). Then I rebooted and immediately verified my configuration as in the wiki, enabled NetworkManager under systemd, and rebooted once again. Sometimes I found if you changed the config and continued without rebooting it would cause problems so that is why I reccomend the extra reboot after say changing your hostname under systemd.

You might be better off just getting the openRC system up with a base install and then switching to systemd, and finally installing your WM/DE. I know you said you had problems switching before but it seems to be working very well now for most as long as you read the instructions and do not hit a corner case.

As already said basically if you want to use Gnome3 you pretty much need to use systemd. There may have been some hacks (I think funtoo had/has something) to get it working without it before but the status of them seems cloudy IMO. It's your system so your call though. :)

UUIDs. you are probably okay without them. I have 5 disks with four of those in a btrfs raid1 array. I've never ran into any issues. OTOH if you like to swap your drives around a lot it might be a good idea to use the UUIDs.

The split /usr thing has already been explained. Generally you probably do not want to do that. It will only cause you problems going forward and should be considered an advanced option at this point. It seems most upstream consider it unsupported or deprecated.

CFLAGS. I'd probably just keep it simple. I have an intel core2 quad and I simply use: 'CFLAGS="-march=native -O2 -pipe -ggdb"'

PS- Chronotrigger was awesome. That is one of my favorite games of all time!
Back to top
View user's profile Send private message
ian.au
Guru
Guru


Joined: 07 Apr 2011
Posts: 434
Location: Australia

PostPosted: Wed Jul 15, 2015 7:34 am    Post subject: Reply with quote

G_S
Gentoo systemd integration is excellent. Gnome3 under systemd runs flawlessly and has been my main desktop since it went stable. Gnome3 is tied to systemd too tightly for it to be trivial to run/maintain a desktop machine without it.

Systemd noise is everywhere, I stay out of that. I migrated all our desktops because I tried Gnome3 under systemd and liked it. A few problems early-on, sure; missing service files mostly, but that was almost 2 years ago (more or less, whenever it went stable). The world kept turning, documentation improved, service files got written, and today my office installs are rock solid stable thanks to the excellent work done by the devs and volunteers here.

Gentoo approaches systemd the right way imo, it's optional, works brilliantly if you want it, and; is perhaps slightly easier than openrc in terms of getting a fully-fledged multi-seat DE up and running (although I haven't spun up a more recent *dev/openrc/X for a while, maybe that got quicker and easier over the past couple of years too). It's relatively simple to switch fully back to openrc if needed, or to boot a minimal openrc shell by changing a kernel parameter (or used to be, haven't done that in a while).

On the initramfs question, that's not required unless you move from a standard handbook install (separate /usr partition). I find it easier to keep /usr under / and; unless you have a specific reason, wouldn't bother changing it.

Follow the handbook closely whichever way you go and get the system you *want* to use. If you do use systemd there's no way around learning some new tools / approaches wrt to the way services run, start, stop and depend on each other.

I'm only running intel boards these days but had a look at the Wiki link, and you're in the right place there. You would need to post the output of
Code:
grep -m1 -A3 "vendor_id" /proc/cpuinfo
for more specific help with that.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43192
Location: 56N 3W

PostPosted: Wed Jul 15, 2015 7:38 am    Post subject: Reply with quote

davidm,

Split /usr works fine. I was intending to try out sLongs patches to start udev after /usr (and /var in my case) were mounted.
However, nothing broke, so I didn't have a test case. Its more a depreciated option, so devs can allow separate /usr to break rather than doing extra work going against $UPSTREAM.

If you like filesystem UUIDs you will like partition UUIDs even more. Filesystem UUIDs need the userspace mount tool, hence an initrd to be used for mounting root. The kernel understands partition UUIDs for itself.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
dantrell
Guru
Guru


Joined: 01 Jun 2007
Posts: 565
Location: Earth

PostPosted: Thu Jul 16, 2015 4:08 am    Post subject: Reply with quote

Gloom_Scythe wrote:
I was planning on using gnome. So I can use gnome with openrc if I remove policykit/consolekit? I like fluxbox too but setting up the menus is a pain. I was under the impression it was impossible to run gnome without systemd. Is there a guide you can reference? Well I use gentoo on a second ssd dedicated for gentoo.... Do I still need to use UUIDs? I usually install the bootloader on the first harddrive containing win7 (for the moment). I have only used gnome, kde, and fluxbox. I am not a big fan of kde. Are there any DE's you would recommend I try? There are quite a few I see.


Thank you for the input.


You can run GNOME without systemd easily. In fact you have two choices depending on whether or not you need basic functionality. Both of these choices have been covered on the post I just made regarding GNOME Without Systemd.
_________________
Dantrell B.
Back to top
View user's profile Send private message
ian.au
Guru
Guru


Joined: 07 Apr 2011
Posts: 434
Location: Australia

PostPosted: Thu Jul 16, 2015 4:49 am    Post subject: Reply with quote

Interesting read Dantrell,

Quote:
You can run GNOME without systemd easily.

Well you've done a heap of work to get to the stage where it's 'easy' by the look of things :)

That said, I'm going to build your patched version and have a play around when I get some spare time. Thanks for posting it.

Edit: I still think the OP should try and get a supported install working first.
Back to top
View user's profile Send private message
Gloom_Scythe
n00b
n00b


Joined: 01 Sep 2014
Posts: 12

PostPosted: Sat Jul 18, 2015 9:49 pm    Post subject: Reply with quote

Thank you all for the advice.

I will be doing the install with Openrc and xfce4 as suggested. I would rather not use systemd if I do not have to. Wish I had a printer. I am hand copying the guide. I might use link or lync to look at it while using the minimal cd. Will be hard to get screenshots so if I have any issues during the install I will have to write them down. I had issues setting up Xorg last time. Xorg is way different than it used to be and I have an HIS R9 280 graphics card. I plan on installing wine to see if my windows programs work. I will have to use the ati proprietary drivers (I play pc games from time to time). I think this time I will use ACCEPT_KEYWORDS="amd64" instead of "~amd64". I do however emerge the newest gcc, glibc, and kernel headers during the install. I used to use the stage1 install when it existed back then. Anyways I will report back any issues I encounter. Chrono Trigger is one of my favorite games as well. I like all the "old school" rpgs. Not big on the new ones. I have been playing Tactics Ogre on my psp recently. Going to be a life saver after my upcoming surgery. I do not swap out hard discs at all. I have 2 SSDs so I wrote down how to enable TRIM support in ext4. I have been using arno-iptables firewall because I do not know iptables all that well. I had another side question. I am a paranoid person in regards to pc security. Would I ever have to worry about my pc being penetrated while on the net using the minimal livecd? I make sure to edit the sysctl.conf before I connect to the net but I am not sure if it is possible to set up a firewall while using the minimal livecd? The reasons I ask about the minimal livecd security is because I noticed some odd /etc files. Example rmt or rbash. I do not remember seeing these a couple of years ago. I disable or at least try to disable all remote tools on the machine.
Back to top
View user's profile Send private message
Buffoon
Veteran
Veteran


Joined: 17 Jun 2015
Posts: 1074
Location: EU or US

PostPosted: Sat Jul 18, 2015 10:25 pm    Post subject: Reply with quote

Use SystemRescueCD, from USB or CD, choice is yours. Start GUI, open the Handbook in the browser and open a terminal window for install. You can copy and paste from terminal window to GUI browser. You can use wgetpaste to post links to logs that are too big for forum posting.
Back to top
View user's profile Send private message
Gloom_Scythe
n00b
n00b


Joined: 01 Sep 2014
Posts: 12

PostPosted: Sun Jul 19, 2015 4:51 am    Post subject: Reply with quote

I prefer the minimal cd over the SystemRescue cd. I use link to browse the net :). Just installed with only one annoyance. I noticed I had something called FlexNet in my mbr at sector 32.... (I know autocad and adobe products use FlexNet but I am to poor own AutoCad hehe) The fix I found on the net is: dd if=/dev/zero of=/dev/sda bs=512 count=1 seek=32. Not sure how that bugger installed itself in my mbr. I do not use anything adobe. Hopefully the mystery program I have installed doesn't reinstall FlexNet again. Have any of you ran into this?
Back to top
View user's profile Send private message
Roman_Gruber
Advocate
Advocate


Joined: 03 Oct 2006
Posts: 3806
Location: Austro Bavaria

PostPosted: Sun Jul 19, 2015 8:38 am    Post subject: Reply with quote

md5sum your /boot + mbr and never mount it again
than just compare with a scipt on every boot your md5 checksum.
Back to top
View user's profile Send private message
Gloom_Scythe
n00b
n00b


Joined: 01 Sep 2014
Posts: 12

PostPosted: Tue Jul 21, 2015 12:09 am    Post subject: Reply with quote

Today I successfully installed alsa with no issues but when trying to install xorg I ran into issues... I have some questions in regards to installing xfce4, xorg, and ati drivers. Do any of you use the profiles? I never used to but according to the xfce4 wiki I selected profile 3 (the generic amd64/desktop profile). My cflags are -O2 march=native -mprefer-avx128 -mvzeroupper -pipe" The USE flags I have manually entered thus far are: USE="nptl nptlonly mmx mmxext sse sse2 sse3 ssse3 sse4_1 avx avx2 X xcomposite opengl openal -bluetooth branding -cups dts dvd dvdr ffmpeg flac -ftp -geoip -gnome -systemd -kde lm_sensors mp3 mp4 mpeg ogg vorbis png -samba -rdesktop -vnc smp sound ssl tcpd alsa wmf wavpack -wifi -vhosts jpeg jpeg2k gif -scanner" (so far). When I emerge xorg-x11 for some reason its trying to pull in a bunch of mips packages and ppc/ppc64 packages. I also notice its trying to pull in packages from gnome. The mips/ppc abi packages could not be satisfied. I am using ACCEPT_KEYWORDS="amd64" and have made quite a few edits to the package.keywords file. Is this normal for packages to be pulled in for mips and ppc arch? Emerge --info only mentions amd64. I would have more info but have no way to screenshot it. Neddy you said you have xfce4 installed without systemd? Is this normal. I am going to stop until I hear from you guys because this does not look normal. Did you use any desktop profiles? Could these USE flags be causing any issues? Did you use the xorg-x11 or xorg-server package? I dont want to edit to much because I dont to accidentally pull in systemd hehe.

I notice that the ALSA_CARDS variable in the emerge --info lists audio cards which are not installed. Should I manually set the ALSA_CARDS variable in make.conf to only list my audio card? If you require the logs I can probably use a flash drive to grab the logs and post on here. Thank you all for the help. I tried switching the profiles back to profile 1 and noticed that solved the issue with pulling in gnome packages when trying to emerge xorg but it did not solve the issue with trying to pull in mips and ppc/ppc64 packages...?


tw04l124 - What do you mean MD5SUM my /boot? What would that do to help me avoid the FlexNet thing? I only know flexnet is some licensing software. Unless I have a bootkit virus of some kind..?
Back to top
View user's profile Send private message
ian.au
Guru
Guru


Joined: 07 Apr 2011
Posts: 434
Location: Australia

PostPosted: Tue Jul 21, 2015 4:09 am    Post subject: Reply with quote

Quote:
sse sse2 sse3 ssse3 sse4_1 avx avx2

Pretty sure avx2 is not supported on your arch? AMD9370 Not that that is probably your only problem here.

You didn't post your cpuinfo, and I don't have a machine with that processor in it, but I think march=bdver(X) is a better choice on amd as it will superset your instruction set:
Code:
FMA4, AVX, XOP, LWP, AES, PCL_MUL, CX16, MMX, SSE, SSE2, SSE3, SSE4A, SSSE3, SSE4.1, SSE4.2, ABM
and 64-bit instruction set extensions.
more if reqd:
https://gcc.gnu.org/onlinedocs/gcc/x86-Options.html#x86-Options

Can I suggest you go back and look at the handbook, it covers all of this. You don't need to set too many flags on first pass, just get your basic system up and running, you can try to rice it later, after you have a chance to observe what the basic build provided. These days it's rare that I need to add more than the base flags from the handbook for a desktop install. I don't use march=native unless there is no better alternative.

You want to run a desktop, so start with the basic desktop profile. Again this will set most of the basic elements in place for you to build a basic, bootable X system. You don't have to make it hard, although Gentoo makes making it hard, err easy :) sometimes there are just too many options.

It doesn't help much to say:
Quote:
made quite a few edits to the package.keywords file. Is this normal for packages to be pulled in for mips and ppc arch?

how can we tell? post the output of the file, it's hopeless to just say you changed it.

ALSA_CARDS I think that is the default behaviour. I don't even know if the ALSA_CARDS= is still supported in make.conf I can't remember the last time I set it.

Flexnet issue is an old one; from dual booting a windows machine, if you got your mbr clear and are booting (and don't reinstall windows :) ) I doubt you'll see it again.

Edit: BTW you should really change the title of this post, as you have decided not to use systemd, it's misleading. There are many here who won't look past the title as they don't use / support systemd.
Back to top
View user's profile Send private message
Gloom_Scythe
n00b
n00b


Joined: 01 Sep 2014
Posts: 12

PostPosted: Tue Aug 04, 2015 11:29 pm    Post subject: Non-systemd install on a current system Reply with quote

Well I was looking at: https://wiki.gentoo.org/wiki/Safe_CFLAGS#FX-XXXX
I think I should not have used -march=native as someone else suggested. I read the link you posted makes way more sense. I do however think (from the link you posted and the one I have looked at above) the following flags (-mprefer-avx128 -mvzeroupper) would be beneficial based on my processor. I have my base system compiled with no problems it actually seem pretty darn quick. Maybe I will reinstall the base system with march=bdver2 (this is the model output from cpuinfo). I made a huge mistake with avx2... I will re-read the handbook again and try again this weekend. Thank you for your input. I do not see an edit button on the top of the thread. Originally I was going to use systemd because I thought that was the only choice I had now... I just dont know what use flags I need to -out so I dont get any systemd files. I noticed even having USE="-systemd" put a systemd config folder in /etc..... I thought if I used the USE="-programname" that it would not get pulled in. Does setting the profile over ride custom USE variables? Sorry for all these questions. I know I have used gentoo for along time but not on this more up to date system and (-6 years....). :). I remember when someone (cant remember who) made a kernel patchset that included the nvidia driver hehe.


Thank you - sorry for the late post. I have been very busy.
Back to top
View user's profile Send private message
EmaRsk
Apprentice
Apprentice


Joined: 07 Sep 2004
Posts: 158
Location: Italy

PostPosted: Wed Aug 05, 2015 11:59 am    Post subject: Reply with quote

Regarding the CPU related USE flags, are you aware of app-portage/cpuinfo2cpuflags? It prints the USE flags supported by your CPU.
_________________
Please, avoid some common spelling errors:
http://theoatmeal.com/comics/misspelling
Back to top
View user's profile Send private message
ian.au
Guru
Guru


Joined: 07 Apr 2011
Posts: 434
Location: Australia

PostPosted: Wed Aug 05, 2015 2:19 pm    Post subject: Reply with quote

If you want to run without systemd, go with the openRC/Xfce desktop instructions here https://wiki.gentoo.org/wiki/Xfce It really is the only way afaict.
There's more to systemd than just the init so if you plan to use kde eg. and need networkmanager, you'll start to pull in systemd deps despite the flags as you're finding.
If you're going to start pulling it in, imo, you may just as well drink the kool-aid and get the init it was all designed to work with.

To me its systemd for gnome or kde essentially, all the non systemd kde does afaict (haven't used it for years, but looked at it closely when gnome went for hard deps on *d) is allow you to avoid the init part of systemd, which seems a rather pyrrhic victory to me.

Glad you got the other stuff done. Those flags look fine, btw. I wouldn't change the march= unless you have a good reason, distcc or the like. Hope the above is some use anyway, whatever you decide to do, do it with productivity in mind, you're clearly busy :)
Back to top
View user's profile Send private message
RazielFMX
l33t
l33t


Joined: 23 Apr 2005
Posts: 835
Location: NY, USA

PostPosted: Wed Aug 05, 2015 2:27 pm    Post subject: Reply with quote

Personally, I find the following USE flags to be ideal if you are building on the system you are running (and don't run it on a different CPU):

Code:
-march=native -mtune=native -O2 -pipe


I'm pretty sure march implies mtune for x86_64 architecture so it may not be required (it has been awhile since I've run gentoo and am too lazy to dig up my old make.conf).

If you are looking for cross hardware usage, you can relax the march/mtune to something less optimized. Native is only a problem if you using a bleeding edge CPU that your GCC version doesn't fully support or you want to build a system and use it as an image with which to base other systems with different hardware.

As for systemd... my only Linux system right now is Arch on VMWare so I am forced to use systemd. It does the job, but it is like a bad rewrite of OSX's launchd (since the VM is actually running on top of OS X Yosemite, I get to see the contrast constantly). The binary logging sucks (not even Apple uses binary logging). My VM is basically a minimal KDE desktop that I use for building maven and cmake projects, so the annoyances of systemd are tolerable since I do so little with the VM. It was a pain to get working with systemd as I needed to manually set up all the VMWare support (Arch is not a directly supported Linux flavor for VMWare, so no "easy install") and systemd is no where near as intuitive as OpenRC.

Given a choice, I would take OpenRC (and syslog-ng; I never thought I'd miss a syslog implementation) over systemd any day. However, if you are forced to use systemd because of the constraints you are under (mine was speed of implementation and thus a binary distribution; Arch was an easier pill to swallow than Ubuntu or a Red Hat clone).

My next bare metal Linux build will be Gentoo without systemd.
_________________
I am not anti-systemd; I am pro-choice. If being the latter makes you feel that I am the former, then so be it.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum