[06:20] <lordievader> Good morning
[07:29] <friendlyguy> morning
[07:37] <friendlyguy> is somebody willing to work with me to get old kernels automatically removed?
[07:38] <friendlyguy> i have an old system where this isnt working
[07:38] <friendlyguy> i worked with tomreyn and rbasak yesterday on this: removed most of the old kernels manually
[09:06] <Skyrider> Greetings all
[09:06] <Skyrider> Was wondering if someone could help me with a tiny problem. I noticed today that php curl was no longer functioning.. I checked it out and saw that I can't install curl at all: "php7.2-curl : Depends: libcurl4 (>= 7.44.0) but it is not going to be installed" --> But if I install libcurl4, it'll erase my mongodb 4.x server installation.
[09:07] <Skyrider> Any suggestions?
[09:24] <tomreyn> friendlyguy: i could help there if you like? if so, post the http address returned by 'dpkg -l | grep ^....linux | nc termbin.com 9999' to get started.
[09:36] <friendlyguy> morning!
[09:36] <friendlyguy> cool, sure
[09:37] <friendlyguy> but i guess ill need to open that port first
[09:38] <friendlyguy> gimme a sec
[09:40] <friendlyguy> https://termbin.com/j4j7
[09:40] <friendlyguy> opening that port did help :)
[09:44] <tomreyn> friendlyguy: welcome back. be sure to type "tomreyn" here to raise my attention. what does "uname -r" say is the kernel version currently running?
[09:54] <friendlyguy> tomreyn: its 4.4.0-154-generic
[09:56] <tomreyn> friendlyguy: sudo /bin/true && ( sudo apt-get update && sudo apt-mark auto linux-image-4.4.0-154-generic linux-headers-4.4.0-154-generic && sudo apt-get install linux-generic ) > /tmp/tomreyn && cat /tmp/tomreyn | nc termbin.com 9999
[09:56] <tomreyn> please pass the url and tell me if it prints anything on screen other than the url, too.
[09:59] <friendlyguy> https://termbin.com/95ei
[09:59] <friendlyguy> no errors were shown
[10:06] <tomreyn> friendlyguy: please keep highlighting me (putting my name in front of what you say). the output looks fine (despite it being in german, but then i personally understand that; you could run "export LANG=C" to get output in english). now: sudo apt-mark manual linux-generic
[10:07] <friendlyguy> tomreyn: thats done
[10:07] <friendlyguy> "has already been marked manual..."
[10:11] <tomreyn> friendlyguy: sudo apt-mark auto '^linux-(image(-extra)?|(cloud-)?tools|headers)-4.*' | grep -v 'not installed.' | nc termbin.com 9999
[10:16] <friendlyguy> tomreyn: https://termbin.com/reu6
[10:17] <friendlyguy> oh, damn. i should have changed "not installed." to its german equivalent
[10:17] <friendlyguy> sorry
[10:18] <tomreyn> friendlyguy: just run   export LANG=C      - it will only last for this ssh session
[10:18] <friendlyguy> i created a new one: https://termbin.com/a02g
[10:19] <friendlyguy> did the export also now
[10:20] <tomreyn> friendlyguy: and no worries. ;)  as a reminder, this tells you what your currently running kernel is:  uname -r      run it to remind yourself. then:   sudo apt-get update && sudo apt --purge autoremove       and make sure you read the list of software it wants to uninstall. it should not include the currently running kernel. if it does, cancel removal.
[10:21] <friendlyguy> tomreyn: it does not want to uninstall anything
[10:21] <tomreyn> okay, that's fine, too
[10:22] <tomreyn> friendlyguy: now:   nc termbin.com 9999 < /etc/apt/apt.conf.d/01autoremove-kernels
[10:23] <friendlyguy> tomreyn: https://termbin.com/4k7l
[10:29] <tomreyn> friendlyguy: hmm this linux-image-extra-4.4.0-142-generic package is not in a good state. let's try to fix this:  sudo apt purge linux-image-extra-4.4.0-142-generic     and post the output to https://paste.ubuntu.com
[10:31] <friendlyguy> tomreyn: how do you know? i couldn`t see that its in a bad state
[10:36] <tomreyn> friendlyguy: on what you just posted, there was this line: pH  linux-image-extra-4.4.0-142-generic   4.4.0-142.168                                amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
[10:36] <tomreyn> you can produce this line using this command:   dpkg -l linux-image-extra-4.4.0-142-generic
[10:37] <friendlyguy> pkg-query: no packages found matching linux-image-extra-4.4.0-142-generic
[10:37] <friendlyguy> tomreyn: thats interesting
[10:38] <tomreyn> the 'pH' it starts with says this package is in a state where it is to be (p)urged but it is also (H)alf-installed. the p isn't an issue but the H should not be there.
[10:38] <tomreyn> you could read up on this after installing the manuals
[10:38] <tomreyn> !man
[10:38] <tomreyn> and running:   man dpkg-query
[10:39] <tomreyn> (to quit this viewer when you finished reading, press 'q')
[10:39] <friendlyguy> tomreyn: Package 'linux-image-extra-4.4.0-142-generic' is not installed, so not removed
[10:39] <friendlyguy> i wonder which output you are looking at?
[10:40] <tomreyn> right, i'm puzzled as to why it's saying this now.
[10:40] <tomreyn> i'm looking at https://termbin.com/4k7l
[10:40] <tomreyn> maybe     dpkg -l | grep ^.H     will produce this output
[10:42] <friendlyguy> tomreyn: nope
[10:42] <friendlyguy> didnt return anything
[10:42] <tomreyn> ok, another explanation is that this package was only in this state at the time because it was just being worked on by an automatic background process at the time
[10:43] <tomreyn> so since it's just uninstalled now we don't need to worry about it
[10:43] <tomreyn> is rebooting this system an option currently?
[10:43] <tomreyn> (don't do it, yet)
[10:43] <tomreyn> friendlyguy: ^
[10:45] <friendlyguy> yes, sure
[10:45] <friendlyguy> no problem
[10:45] <friendlyguy> tomreyn: i can reboot it anytime
[10:47] <tomreyn> friendlyguy: okay, let's make sure all the latest software is installed:  sudo apt full-upgrade
[10:47] <friendlyguy> tomreyn: it is
[10:48] <tomreyn> hmm weird, i have a newer kernel version installed. can i see    dpkg -l | grep ^....linux | nc termbin.com 9999   again?
[10:49] <friendlyguy> tomreyn: sure, https://termbin.com/bagv
[10:50] <tomreyn> oh, my bad, i have an extra repository enabled which provides newer versions which are still undergoing testing.
[10:50] <friendlyguy> ah, alright. thats clear then :)
[10:51] <tomreyn> okay, so just reboot, and then run   sudo apt update && sudo apt --purge autoremove     and tell me whether it wants to remove anything
[10:52] <tomreyn> or rather if it wants to remove anything there, please show the full output on the pastebin.
[10:56] <friendlyguy> tomreyn: nothing
[10:59] <tomreyn> friendlyguy: okay, then run this to hopefully remove the outdated packages:   sudo apt purge '^linux-(cloud-tools|headers|image|image-extra|tools)-4\.4\.0-1[0-4][0-9](-generic)?$'
[10:59] <tomreyn> friendlyguy: if it prompts, don't confirm, yet
[10:59] <tomreyn> just show the output
[10:59] <tomreyn> friendlyguy: oh and please also show    uname -r    once more
[11:10] <tomreyn> friendlyguy: got busy?
[11:37] <tomreyn> friendlyguy: i'm gone for ~ 1 hour. in case you'll return in the meantime, make sure no package containing your current kernel version (as reported by "uname -r") is listed by the "apt purge ..." command. if so, confirm it. that should be all that's left to be done.
[11:49] <rbasak> tomreyn: you don't know about pastebinit?
[11:49] <rbasak> It's a package ;)
[11:50] <friendlyguy> tomreyn: ah, sorry. went for lunch
[12:11] <friendlyguy> tomreyn: https://paste.ubuntu.com/p/2G9vyB9JVP/
[12:17] <tomreyn> rbasak: i know ;) but it's not installed by default, and throws warnings which irritate people on 19.04. thanks for the hint, though.
[12:18] <tomreyn> friendlyguy: welcome back. you can confirm this prompt.
[12:18] <rbasak> https://bugs.launchpad.net/ubuntu/+source/pastebinit/+bug/1812232
[12:18] <rbasak> Disco isn't really Won't FIx - it just needs someone to drive it.
[12:27] <tomreyn> i agree. :)
[12:28] <friendlyguy> tomreyn: i am done with that, all removed
[12:32] <tomreyn> friendlyguy: okay, then we're done. you could duble check that there are no old leftover files in /usr/src/ and /boot/ if you like. i expect that older kernels will be automatically marked for removal from now on. if you like to, review the comands we ran and ask about them if you have any questions.
[12:34] <friendlyguy> i understood the commands, but i didnt get the "big picture" totally i think
[12:35] <friendlyguy> we basically removed old kernels, and made sure the current kernel is flagged as automatic, ist this correct?
[12:35] <tomreyn> friendlyguy: yes, that's really all we did i think
[12:36] <friendlyguy> can you guess what i screwed up to get in this situation?
[12:38] <tomreyn> friendlyguy: flagging those versioned kernel images as automatic, and, moreover, making sure the non versioned 'tracking' packages (linux-generic, linux-image-generic) are installed should make the automatism defined in /etc/apt/apt.conf.d/01autoremove-kernels work so that older kernel packages will get flagged to be removed by apt autoremove
[12:40] <tomreyn> this is a not only an issue on your very system but was a more common issue on 14.04 and earlier (but not on 18.04, and i think not on 16.04 fresh installations - so unless it was upgraded to).
[12:42] <tomreyn> friendlyguy: so i assume you upgraded this system from an earlier release at some point. but i may also be wrong in that it did actually still happen on earlier 16.04 point releases.
[12:42] <friendlyguy> yeah, the vm is about 10 years old
[12:42] <friendlyguy> i run a bunch of websites on it
[12:42] <friendlyguy> nothing critical
[12:43] <tomreyn> oh, so it went thruogh several upgrades. then i recommend you run https://github.com/tomreyn/scripts#foreign_packages
[12:43] <tomreyn> also deborphan
[12:46] <friendlyguy> tomreyn: ill do that, thanks
[12:46] <friendlyguy> i was thinking about to do another release upgrade
[12:47] <friendlyguy> 16.04 to 18.04
[12:49] <tomreyn> friendlyguy: you'd get TLS1.3, which is nice - faster web browsing on sites you host.
[12:50] <tomreyn> !releasenotes
[13:26] <friendlyguy> tomreyn: thanks a lot for you help again!
[13:27] <tomreyn> you're welcome, friendlyguy
[16:34] <supaman> I have a webserver that is accessed by some finnish people that use the ä letter (hex e4) is some filenames that are uploaded to the server
[16:35] <supaman> when I look in the folder I see $344 instead of the letter
[16:35] <supaman> and most importantly I have problems backing up the folders using rsync to a smb mounted NTFS filesystem, it gives an error
[16:36] <supaman> why is this happening? using find, printf and xxd to see the hex values in the filenames it gives the correct hex value
[16:37] <supaman> so my system (ubuntu 18.04 on ext4) is not displaying the character correctly
[16:38] <supaman> and then rsync, smb, or something else in the stack is crapping out moving those files to the smb mount
[16:38] <rbasak> Everything needs to be set up to use the same encoding, or be able to determine the encoding correctly
[16:38] <rbasak> That includes your locale, etc.
[16:40] <supaman> locale is en_US.UTF-8
[16:41] <supaman> interesting, if I do a "touch täst" on the server, and check the hex value of ä I get a different value
[16:42] <supaman> if I type it I get hex value c3, but in the filenames its e4
[16:47] <RoyK> it's probably russian cyber-terrorists trying to get in :D
[16:47] <supaman> hehe :-)
[16:48] <supaman> nah, finnish environmentalists ... even worse ;-)
[16:52] <tomreyn> 0xc3 would by Ã
[16:52] <supaman> in en_US.UTF-8?
[16:52] <tomreyn> yes. echo -e '\uc3 \ue4'
[16:54] <supaman> even more interesting, I created an empty file with ä (not Ä) in the name, ran it through find . -maxdepth 1 -type f -exec sh -c 'printf "%-10s %s\n" "$1" "$(printf "$1" | xxd -pu )"' None {} \; and that shows 0xc3 for ä
[17:01] <supaman> hmmm ... a bit more convoluted, ./täst gives me 2e2f74c3a47374 ... so its c3a4 that represents the ä
[17:04] <tomreyn> AKA "LATIN SMALL LETTER A WITH DIAERESIS"
[17:04] <supaman> never got used to the names of all those commas and umlauts over letters
[17:08] <supaman> could be the difference is since I have an icelandic keyboard layout and need to press two keys (one dead key) to get the ä
[17:08] <tomreyn> it's the (web searchable) description of this character from the unicode standard
[17:10] <tomreyn> http://www.ltg.ed.ac.uk/~richard/utf-8.cgi?input=%C3%A4&mode=char
[17:10] <supaman> c3a4 is the utf-8 computer encoding, e4 is the iso-8859 encoding (according to https://en.wikipedia.org/wiki/%C3%84)
[17:11] <tomreyn> so if you see Ã somewhere then it's due to LATIN-1 (i.e. non utf-8) encoding
[17:11] <tomreyn> meaning you have a character conversion to non utf-8 in place, which is your 'bottleneck' there.
[17:11] <tomreyn> well, not conversion, lack of conversion really
[17:13] <supaman> yeah, seems that when the files where uploaded to the server the filenames got stored as iso-8859 but now the system is in utf-8 mode and then it doesn't know what to do with the character
[17:28] <hallyn> ubuntuserver.wordpress.com deleted?
[18:09] <coreycb> jamespage: python3-ceilometerclient BDs have been removed except for vitrage: https://storyboard.openstack.org/#!/story/2006269
[18:10] <coreycb> jamespage: mistral's dependency on python-glareclient may be difficult since glare is at least somewhat maintained still
[18:17] <jamespage> coreycb: thanks
[18:17]  * jamespage ponders glareclient
[18:17] <jamespage> I guess we can leave the client package in place for the time being...
[18:18] <coreycb> jamespage: alright i'll take a look at updating glare packages to py3 only