#linuxcnc-devel Logs

Jul 02 2019

#linuxcnc-devel Calendar

03:02 PM memfrob: andypugh, thank you for the nice note about me on the mailing list :)
03:05 PM andypugh: I think I am getting close
03:05 PM andypugh: I have a shmem limit problem
03:05 PM memfrob: /etc/security/limits.conf ?
03:05 PM andypugh: and, a wierd: -bash: ulimit: max locked memory: cannot modify limit: Operation not permitted
03:05 PM andypugh: sudo ulimit -l 20480
03:05 PM andypugh: sudo: ulimit: command not found
03:05 PM memfrob: sudo su - root
03:05 PM memfrob: I know it sounds stupid but sudo isn't perfect
03:05 PM memfrob: but you should really use /etc/security/limits.conf
03:05 PM andypugh: Yes, I have done that
03:05 PM andypugh: It’s just a pin rebooting and logging back in to everything.
03:05 PM memfrob: and sudo make setuid?
03:05 PM andypugh: because I am working through ssh
03:07 PM memfrob: any undefined symbols in dmesg?
03:07 PM andypugh: Oh, one thing… Your RTAI kernel config leads to a “Spectre Mitigation…..” message at boot, and a suggestion of a config to change. Is that deliberate?
03:08 PM andypugh: No the undefined symbols disappeared after a make menuconfig in RTAI.
03:08 PM memfrob: I had issues with the kernel hardening features so they're mostly disabled
03:08 PM andypugh: Which I had tried yesterday, but got “no rule for menuconfig” or something, so I assumed that wasn’t the way to go….
03:09 PM memfrob: panics and very boot problems
03:09 PM memfrob: *very early
03:09 PM memfrob: you have to run ./autogen.sh which generates the makefiles then you can run make menuconfig
03:09 PM andypugh: I might try turning the “whatever it suggests” on, see what happens
03:09 PM memfrob: the README.INSTALL file has all that in there
03:10 PM memfrob: whatever what suggests where?
03:10 PM andypugh: Tho kernel boot message
03:11 PM andypugh: “spectre mitigation not possible, please enable……”
03:11 PM memfrob: spectre mitigation is disabled via Kconfig patch
03:11 PM memfrob: it doesn't work
03:12 PM andypugh: OK.
03:13 PM andypugh: Maybe I need to work on gettting the network interface up earlier so that the message scrolls past quicker :-)
03:14 PM memfrob: it's a harmless message and i don't think linuxcnc users need to worry too much about spectre/meltdown
03:16 PM memfrob: if you're going to get attacked, it's going to be through the network or running a malicious installer embedded in an "appimage" file
03:19 PM andypugh: Anyway, “Woohoo” I have LinuxCNC running on RTAI
03:20 PM memfrob: what step did you miss?
03:21 PM andypugh: it was the menuconfig
03:21 PM andypugh: I had tried it, but it refused.
03:21 PM memfrob: ah
03:21 PM memfrob: yeah RTAI has all the makefiles and such generated via ./autogen.sh -- the build system is made mostly on the fly
03:22 PM andypugh: It was late, I probably tried “make menuonfig” or something.
03:22 PM memfrob: i did it this way to trim LOC footprint and make maintenance and tracking easier
03:22 PM memfrob: also the reason i pulled comedi and other features out
03:23 PM memfrob: well i'm glad it's all working now!
03:23 PM andypugh: Next step, I suppose, is to make debs…
03:24 PM memfrob: I'd use this as reference: https://github.com/SebKuzminsky/rtai/tree/vulcano-debs-2017-05-19/debian
03:25 PM memfrob: you won't need a lot of those options though, i have the recommended settings already enabled in the ./configure file
03:25 PM memfrob: you wont need any of the newlib stuff either
03:26 PM andypugh: I have a lot of studying to do, I suspect.
03:26 PM memfrob: everything is in rules.in
03:26 PM memfrob: you'd delete most of what's in there is all
03:29 PM memfrob: http://dpaste.com/2SS6EAS as a start
03:31 PM memfrob: line 32 should be ./autogen.sh
03:31 PM memfrob: ./autogen $(CONFIGURE) works too
03:31 PM memfrob: I mean: ./autogen.sh $(CONFIGURE)
03:32 PM memfrob: compiling the kernel, it used to be as easy as make-kpkg
03:32 PM memfrob: but that doesn't work as well as it did.
03:33 PM memfrob: you download source from kernel.org and run make-kpkg and it would just automatically build a deb package
03:33 PM memfrob: now it needs a control file and all that stuff
03:34 PM andypugh: Is it as simple as copying the “debian” folder from seb’s repo into my copy of your RTAI repo?
03:35 PM andypugh: (as a starting point)
03:35 PM andypugh: I assume that sebs stuff is for making RTAI packages, not a kernel package?
03:35 PM memfrob: your assumption is right, and it should be as simple as that with maybe some minor tweaks
03:36 PM memfrob: run it and see what you get, ask seb yourself for any questions about it haha
03:37 PM memfrob: i'll try to help too but I'm not quite as skilled at making deb packages compared to my Gentoo and fedora packaging skills
03:38 PM memfrob: to make a kernel package, like i said, for years i just used make-kpkg but that's being phased out
03:40 PM memfrob: https://wiki.ubuntu.com/KernelTeam/GitKernelBuild .. is it really that easy?
03:41 PM memfrob: make -j `getconf _NPROCESSORS_ONLN` deb-pkg LOCALVERSION=-RTAI and you don't need a debian folder inside the kernel source?
03:42 PM memfrob: deb-pkg automagically works on it's own?
03:51 PM andypugh: I guess I will find out.
03:56 PM memfrob: before you package RTAI, you should delete it's directory and re-clone to start fresh
03:58 PM memfrob: One more thing, I'm not sure if you were here when I said it, but Xenomai dropped 32-bit support starting with kernel 4.14
04:22 PM memfrob: leaving now, good luck to you!
04:31 PM -!- #linuxcnc-devel mode set to +v by ChanServ
05:10 PM -!- #linuxcnc-devel mode set to +v by ChanServ
05:23 PM memfrob: Back now, how's it going?
05:24 PM memfrob: andypugh, I also updated the kernel to 4.14.131, might as well update it for the deb
05:25 PM memfrob: the diff between 130 and 131 only changes a few lines of code but good practice anyway, plus i made some other changes since you patched it
05:25 PM andypugh: memfrob: I am having a learning experience :-)
05:25 PM andypugh: Afrer an hour of compiling, for example, I got: illegal package name 'linux-headers-4.14.130-RTAI-RTAI': character 'R' not allowed
05:26 PM andypugh: So I need to work out how to not have RTAI twice and not to have capital letters….
05:28 PM andypugh: I need to make kernel packages (it seems) to make RTAI packages as otherwise there is no linux-headers-4.14.130 to build against
05:29 PM andypugh: It sounds like you are suggesting starting again from scratch?
05:30 PM andypugh: (with a new pull of RTAI and a fresh 4.14.131 kernel?)
05:30 PM andypugh: I will let this build finish, to see what happens.
05:39 PM memfrob: The one good thing about building packages is that the errors generally are informative
05:40 PM memfrob: Error: $(CC) -- Print Load Letter
06:08 PM memfrob: it'd be a good idea to start from scratch for the debs, yes
06:08 PM memfrob: especially if you plan on posting these somewhere
06:26 PM andypugh: Yes, the plan is that they will be the basis of an alternative package that can be installed from a LiveCD build.
06:27 PM memfrob: then yeah use 4.14.131
06:28 PM andypugh: mozmck_m: Do you think that would work? An ISO that installs uspace + preempt rt, but a package at LinuxCNC.org that depends on RTAI package and matching kernel package as an easy way to get it for thse that need it?
06:29 PM memfrob: I know you're not asking me but i don't see why that would be an issue
07:04 PM mozmck: andypugh: That should work fine. It's great that y'all are getting a newer RTAI+kernel working!
07:04 PM memfrob: andypugh, just took care of some leftover unused code in RTAI, about 2K lines
07:04 PM andypugh: And I now have some acrtual kernel debs
07:04 PM mozmck: andypugh: have you figured out the debian packaging for debian kernels?
07:05 PM mozmck: Oh, sounds like you have!
07:05 PM memfrob: Haha i guess he did!
07:05 PM memfrob: andypugh, was it really as easy as the ubuntu devs said? deb-pkg?
07:05 PM mozmck: Ubuntu has debian packaging patches you can apply to mainline kernels which I normally use. I don't know if debian has something similar.
07:06 PM memfrob: mozmck, the page didn't have anything in there about patching the kernel
07:06 PM andypugh: linux-headers-4.14.130-rtai-x86-64_4.14.130-rtai-x86-64-4_amd64.deb
07:06 PM andypugh: linux-image-4.14.130-rtai-x86-64_4.14.130-rtai-x86-64-4_amd64.deb
07:06 PM memfrob: they just said run make deb-pkg in the vanilla source and it works as-is
07:06 PM mozmck: Yeah, it's not easy to find good and current information.
07:06 PM andypugh: Still work to be done on the name generation…
07:06 PM memfrob: it could have said 4.14.130-rtai-x86-64 a third time!
07:06 PM mozmck: I do believe there is some debian stuff in the vanilla kernel, but I'm not sure how that compares to the ubuntu stuff.
07:07 PM memfrob: the most there is in the vanilla kernel is a helper function for make install
07:07 PM memfrob: nothing to do with debs
07:07 PM mozmck: Those names seem to be what you get linux-image-4.19.50-1-rt_4.19.50-1.rt22_amd64.deb
07:08 PM mozmck: Huh, well I'm not sure what deb-pkg does then.
07:08 PM memfrob: i thought it was debian automagic
07:08 PM memfrob: the dpkg juju!
07:08 PM mozmck: It probably is. Builds a basic debian package structure on the fly or something.
07:09 PM memfrob: i wonder if it works for non-kernels
07:09 PM mozmck: I kind of doubt it. Debian packaging is not too hard really though.
07:10 PM memfrob: make: *** No rule to make target 'deb-pkg'. Stop.
07:10 PM memfrob: Nooooo if only it worked with everything!
07:10 PM memfrob: that means the vanilla kernel makefile has deb-pkg as a PHONY
07:11 PM memfrob: http://dpaste.com/1NPC620
07:12 PM memfrob: Yes, scripts/package/Makefile
07:17 PM memfrob: mozmck, thank you for appreciation
07:17 PM memfrob: I worked on RTAI years ago and it was pretty much ignored, it's nice that people are jumping on it this time around
07:17 PM mozmck: :-) I would have liked to have helped as well (and might still can) but have been pretty busy.
07:18 PM mozmck: I have a number of computers with different chipsets/cpus that I can test on anyhow.
07:20 PM andypugh: Well, that pretty much worked. I put the kernel deb on a USB stick, took it to a VM on my mac, sudo dpkg —install linux…. and it extracted, installed, tweaked grub, made an initramfs and then rebooted into the RTAI kernel.
07:21 PM andypugh: I got to log on but then the graphics screwed up when it tried to use the full Mac screen res. But that’s almost certainly because VMware tools was built under a different kernel.
07:24 PM memfrob: vmware gpus are disabled, depends on too much virtualization stuff that interferes with IPIPE
07:24 PM memfrob: no KVM, no virtualization, no linux guest support or virtual I/O
07:25 PM phillc54: linuxcnc-build: force build --branch=master 2000.docs
07:25 PM mozmck: Yeah, some of that you have to turn off just to disable power saving stuff.
07:25 PM linuxcnc-build: The build has been queued, I'll give a shout when it starts
07:25 PM memfrob: i have all the power saving stuff off
07:26 PM memfrob: i should probably disable I2C ACPI opregion though, considering smart batteries and such are all off too
07:26 PM memfrob: ACPI does not play nice with IPIPE/RTAI
07:26 PM memfrob: I'll add that really quick to the Kconfig, andypugh needs to update it to 4.14.131 anyway so i'll do that before that happens
07:31 PM memfrob: Done.
07:38 PM linuxcnc-build: build forced [ETA 7m59s]
07:38 PM linuxcnc-build: I'll give a shout when the build finishes
07:45 PM andypugh: I put the kernel deb here: http://www.linuxcnc.org/dists/stretch/base/binary-amd64/
07:45 PM andypugh: )It doesn’t show up in the package managers because it isn’t in the package index files)
07:45 PM andypugh: I would be interested to know if that works for anyone else.
07:46 PM memfrob: it's an old 4.14.130 kernel when i was still in the middle of working on it..
07:46 PM andypugh: I will do it all again tomorrow, based on 4.14.131 and clean sources.
07:46 PM memfrob: ok thank you
07:47 PM andypugh: Yes, that’s just to see if I have actually created a working kernel deb that runs RTAI.
07:47 PM memfrob: got it, sounds good!
07:47 PM andypugh: But it is time now for me to sleep.
07:47 PM andypugh: Goodnight all.
07:47 PM memfrob: good night andypugh!
07:49 PM linuxcnc-build: Hey! build 2000.docs #4844 is complete: Warnings [8warnings compile]
07:49 PM linuxcnc-build: Build details are at http://buildbot.linuxcnc.org/buildbot/builders/2000.docs/builds/4844
07:56 PM memfrob: These are the warnings I get: http://dpaste.com/0P1E452
10:15 PM norias: hello
10:30 PM memfrob: norias, Hello! Welcome to the dev channel!
10:31 PM norias: thanks
10:31 PM memfrob: Are you a penguins fan?
10:33 PM norias: by default
10:33 PM norias: i guess