/srv/irclogs.ubuntu.com/2018/03/19/#ubuntu-server.txt

SaadHey, there's anyone running 17+?00:45
SaadThere's no /etc/rc.local anymore?00:45
leftyfbHow can I block all broadcast traffic from a particular vlan? My setup is an interface with 2 tagged vlans but only 1 configured for use. I'd like to block all the ARP and UDP traffic on the unused vlan00:58
=== leftyfb_ is now known as leftyfb
=== chat is now known as Guest910
netham46Any way to run a headless XDMCP server in a VM?05:59
netham46End goal is to have 3 or 4 crappy PCs act as thin clients on the same network as the VM.06:00
netham46End-end goal is to get a PXE boot going where they boot and just connect over XDMCP to it.06:01
cpaelzergood morning06:11
OpenTokixSaad: There is none, but if you make it - it will get run06:49
=== aluria` is now known as aluria
cfncHello guys. Sorry for the question, I made a big mistake. I disabled sudo group to use sudo command from /etc/sudoers but I've never setted a root password.... How can I recover the system without reinstalling the whole os? Could I chroot into the system and change root password?10:07
cpaelzercfnc: yes if you can boot from something else (usb/cd) then you can chroot in10:07
cfnccpaelzer: I'm going to try...10:08
cpaelzercfnc: if you have no other setup that prevents you to mount your disk (encryption, complex multipath/raid/...) then you can also boot  into bash directly10:08
cpaelzercfnc: see https://askubuntu.com/questions/24006/how-do-i-reset-a-lost-administrative-password10:09
cfnccpaelzer: okay I chrooted into system and I changed the password for root user. Thank you ;)10:17
cchahello I have an OUT OF DISK SPACE when I run apt update. But there are more than 7Gb free for /var and 3% inode use10:57
cchaI don't understand why I got the OUT OF DISK SPACE10:58
=== chat is now known as Guest55069
cpaelzerccha: you can be out of space or out of blocks, also you might be out of space on other than /var11:30
cpaelzerhttps://serverfault.com/questions/275206/disk-full-du-tells-different-how-to-further-investigate is a common issue11:30
leftyfbccha: check /boot11:30
cpaelzerccha: but you might just strace the call and see which actually gives you the ENOSPACE11:30
cchaok it wasn't out of space on my server but on the proxy and it was a http message12:17
MitchTwhen is the next azure image due to 'go out'12:48
MitchTfor ubuntuserver12:48
MitchTthe last daily is from the 15th12:48
vimeshello! I am running a small ubuntu webserver hosting now 5 websites, I was told by ...some dude, that the way I do things now. SSHing inn and doing manual config is a horribly bad idea and that I should look into ansible instead. So I'll ask you guys, does me learning ansible to manage one webserver make sense? I usually don't get crashes as I just test things localhost first14:03
leftyfbansible would be helpful to rebuild from scratch14:04
leftyfbother than that, not really14:04
rbasakvimes: I think so. Having a codified deployment is useful when upgrading to a new release too, which you have to do every so often to maintain security support.14:06
rbasakYou can do a do-release-upgrade, but that just leads to your server getting messier over time with less visibility of what's on it and how to rebuild it.14:07
rbasakAnd that typically leads to a bunch of legacy most people could do without.14:07
vimesmmm is ansible the "recomended by you" way to go? I've never used automation tools beyond home cooked bash scripts and cron before14:07
rbasakI'm not familiar with ansible specifically. It seems pretty popular, but so do all the alternatives.14:08
rbasakIMHO, for a small deployment, it doesn't really matter as long as it's flexible enough for you, and the simpler the better.14:08
rbasakFor a tiny deployment, a shell script is fine.14:08
rbasak(or even some handwritten instructions for that matter)14:09
UssatTBH, one server, 5 sites, home cooked scripts are fine14:36
Odd_Blokesmoser: So regarding https://bugs.launchpad.net/cloud-images/+bug/1756420, I'm wondering if we need to defer this to next cycle.14:40
ubottuLaunchpad bug 1756420 in pv-grub-menu (Ubuntu) "replace grub-legacy-ec2 with pv-grub-menu" [Undecided,New]14:40
Odd_BlokeThis seems more complex than a drop-in replacement, and I don't think our team has the cycles to do anything about this before then.14:40
MitchTOdd_Bloke.. do you / your team control the release of versions to azure14:41
MitchT.. timing.. release timing14:42
Odd_BlokeMitchT: Yep, we're responsible for the automation that does the releases.14:47
Odd_BlokeMitchT: On your issue from last week, I believe it was a cloud-init bug that has been resolved; the latest/next image should work.14:48
MitchTOk. I was noticing that the images don't really line up with a specific pattern. Sometimes its one day, others its more than two14:48
MitchTjust trying to learn more about the process since its integral to how our systems deploy.   They are rebuilt completely during each deployment.14:49
smoserOdd_Bloke: I kind of have to agree.15:02
smoserthe other option is to just rip it out of cloud-init source at least15:02
Odd_BlokeMitchT: I'm in a meeting ATM, but I'd be happy to chat about it a bit once I'm done.15:03
Odd_Blokesmoser: You're thinking a separate source package, or a large Ubuntu delta in pv-grub-menu?15:04
smoserseparate source package.15:05
smosernamed grub-legacy-ec2 just not provided by cloud-init.15:05
smosermainly i'd really like to get that out of my ownership15:05
Odd_Blokesmoser: I'd be +1 on that.15:07
smoserOdd_Bloke: i might try to do that then.15:14
smoserand then assign ownership to foundations in some way.15:14
adacI'm following this howto:  https://unix.stackexchange.com/questions/198003/set-default-kernel-in-grub/224708#224708 but there is always just the newest kernel booted still15:40
adacany ideas?15:40
adacI'm on 16.04 btew15:40
adac*btw15:40
MitchTOdd_Bloke i'll be out from 12-1 EST (its 15 till 12 now here) can you meet up later with me on here? i'm interested to know how the images are created that we consume.15:44
MitchTjust DM me a time15:44
dpb1adac: any ideas on what? :)15:45
naccdpb1: 08:40 < adac> I'm following this howto:15:46
nacchttps://unix.stackexchange.com/questions/198003/set-default-kernel-in-grub/224708#224708 but there is always just the newest kernel booted still15:46
dpb1ah15:46
dpb1I missed the bit after the link15:46
adac:)15:47
adacStill happy if anyone has an idea ;)15:48
naccadac: have you checked the result of the sed, etc?15:49
naccadac: that is, the count matches what you want it to ?15:49
adacnacc, actually I tried with sed but also with hand15:49
adacjust adding number with vim15:49
adacbut both did not work actually15:50
naccadac: can you pastebin your /etc/default/grub, and your /boot/grub/grub.cfg ?15:50
adacnacc, ok gimme a sec15:50
=== MitchT is now known as ndac
ndacneeds more confustion.15:51
=== ndac is now known as MitchT
MitchThahaha15:51
* MitchT nice use of the me command15:52
MitchTOH!15:52
MitchTwhat the.15:52
adacnacc, https://gist.github.com/anonymous/d331b098ab22acd9212bd083099ffa8815:52
MitchTok. confused myself.15:52
adacnacc, https://gist.github.com/anonymous/79aa39d649180b468b5601b5f95425f015:53
dpb1adac: I'd actually look at the top upvoted answer.  it looks like 'GRUB_DEFAULT' can be used to point to a specific menuentry-id15:53
dpb1adac: in /etc/default/grub15:53
naccadac: and, to be sure, you're running `update-grub` after, right?15:53
adacnacc, yes i did15:53
adacdpb1, yes I set it to 315:53
dpb1adac: no, somethign like this:15:54
dpb1GRUB_DEFAULT="gnulinux-advanced-65c9af03-3d9b-411c-99b2-a9ada0961a40>gnulinux-4.7.0-1-amd64-advanced-65c9af03-3d9b-411c-99b2-a9ada0961a40"15:54
naccadac: i don't believey you have a 3rd menu entry15:55
dpb1adac: thus making the simple index you are using "3" as not valid15:55
naccadac: i'm not 100% on how grub does it, but you have a top menu then a submenu after it15:55
nacci'm not sure it linearly indexes those15:55
dpb1basically, you see the '>' character?  that is traversing the menu15:55
naccyeah, i think referring by name is better15:56
nacci believe you can actually do it with just the id, dpb115:56
adacnacc, this was the ouptutof this awk15:56
dpb1nacc: yes, I think so15:56
naccthe $menuentry_id_option thing15:56
dpb1nacc: like 2>4 or something15:56
adachttps://gist.github.com/anonymous/3b01096d9a2f28e4594657ac6834914d15:56
naccdpb1: even less than that, you can just use teh unique global id of 4 (iirc)15:56
adacso that is why I used #315:56
dpb1nacc: maybe, have not tried15:56
dpb1nacc: but I hope you are right15:57
naccdpb1: it should be possible, if it's not :)15:57
dpb1+115:57
naccadac: yeah, i'm not 100% convinced that awk is right15:57
naccit's assumign a flat grub.cfg and flat parsing of the indices15:57
adacnacc, would you say it is 2 then :)15:57
naccadac: no15:57
naccadac: read the answer right after that linnk15:57
dpb1adac: I would not trust the answer you linked to.  I would use the top upvoted one15:57
nacc"the indices you can set with grub-set-default only correspond to the main menu entries"15:58
adacdpb1, but this a server i access only via ssh I cannot  slect this manually on boot15:59
dpb1manually?16:00
dpb1adac: the top upvoted answer describes how to modify /etc/default/grub16:00
dpb1https://unix.stackexchange.com/a/327686/916016:00
adacsorry was in the wrong tab16:00
adacyou are right16:00
dpb1np16:00
dpb1I mean, I haven't tried it, but it looks like a sane general approach to fixing this problem.16:01
adacwhich number has it then^^16:01
sdezieladac: if it's a one off test, you can directly editing grub.cfg to reorder the kernels, quick and dirty but should work16:01
adachttps://gist.github.com/anonymous/7bfbeedca71672e6411b5a8404a5d28316:01
adacsdeziel, kk thanks16:04
adaci tried now: 0,1,2,316:05
sdezieladac: that said, at one point I was able to pick a submenu item by editing /etc/default/grub so it should work (sometimes ;))16:05
Odd_BlokeMitchT: Instead of having a time, I think we can just do this asynchronously here.16:05
adacnothing of thsoe works it always the newest kernel booted16:06
Odd_BlokeMitchT: Briefly, we produce a new daily whenever there are changes to packages in the image; for the development series this is generally every day, but for released series this can be further apart.16:06
dpb1adac: are you running update-grub after?16:07
dpb1or are you leaving it alone16:07
Odd_BlokeMitchT: Once that daily has been built, we then consider whether it's a candidate for release; if the packages changed affect first boot (e.g. the kernel, cloud-init), then we also register the image as a release.16:07
adacdpb1, jepp16:08
Odd_BlokeMitchT: We will also manually trigger releases for specific reasons; this most commonly happens for security fixes to packages which aren't in our regular promotion set.16:08
dpb1adac: which16:08
Odd_BlokeMitchT: That's a high-level overview; please do ask me any questions that you have. :)16:09
adacdpb1,16:09
adacwhich update-grub16:09
adac /usr/sbin/update-grub16:09
dpb1adac: update-grub is reverting your changes, unless I'm misunderstanding you?16:10
adacdpb1, I edit the /etc/default/grub file and add the number there. then run update-grub16:12
adacthen reboot16:12
adacand it is always the newest kernel booted16:12
adacvmlinuz-4.13.0-36-generic16:12
dpb1adac: and when you run update-grub, do you notice that grub.cfg reverts the file??16:12
dpb1err, *that grub.cfg is reverted?16:12
dpb1update-grub rewrites grub.cfg.  That's its job.16:13
TJ-adac: which entry do you want to boot from?16:15
adacdpb1, hmm I see. actually when I run update-grub the grub.cfg is reqritten according to the date16:15
dpb1adac: yes16:15
TJ-adac: I find it better to use menuentry names e.g. I have for an entry 2 sub-menus in: GRUB_DEFAULT="Advanced options for Ubuntu 16.04.4 LTS>Linux Mainline-RC for Ubuntu 16.04.4 LTS>Ubuntu 16.04.4 LTS, with Linux 4.16-rc3-pci_bridge"16:15
adacTJ-, yes and this stopped my server from booting16:16
adacI only had time now today again to test this out16:16
dpb1adac: if you are modifying /etc/default/grub, you then need to run 'update-grub', if you are modifying /boot/grub/grub.cfg, you should not16:16
adacdpb1, yes that is what i did16:16
dpb1(modifying /boot/grub/grub.cfg is not a long term fix for just that reason)16:16
dpb1it's for testing out16:16
adacCan i remove the current kernel I'm logged in with?16:17
adacjust for testing16:17
dpb1and it's why I have suggested that you not follow the path you are proceeding with. :)16:17
adacsince I have only two then the old one must be booted :D16:17
dpb1adac: yup, you can also do that for testing16:17
dpb1sure16:17
adacsudo dpkg --purge linux-image-4.13.0-36-generic16:18
adacwould that do the trick?16:18
dpb1I don't know what kernels you have installed, but that is a way to remove one kernel16:19
dpb1and then follow up with apt-get autoremove16:20
adacdpb1, these two https://gist.github.com/anonymous/15cd1ee35967a363e068a07df65333cf16:20
adacok thanks16:20
adaclets see what is happening now :D16:22
TJ-adac: You either use the menuentry titles as I showed "Advanced options for Ubuntu>Ubuntu, with Linux 4.4.0-116-generic or use numbers "0>2"16:22
adacrebooting16:22
adacTJ-, yeah maybe I made  a copy paste error16:22
adacTJ-, "0>2" means?16:23
adacok removing the kernel fixed it16:23
TJ-adac: 0 == first sub-menu, 2 == 3rd entry in that sub-menu16:23
adaci'm now in the old kernel!16:23
MitchTOdd_Bloke: Thanks, that goes a long way towards explaining the cycle. I'm trying to learn what to look for before I release so i'm not ending up being that guy going "whens it happening? Whens the next one" etc.17:25
MitchTbefore *a* release.. not I release.17:31
Odd_BlokeMitchT: The kernel is most often what causes an automated release; new kernels are released on a three week cadence.17:38
=== chat is now known as Guest57765
=== Epx998- is now known as Epx998
MitchTOdd_Bloke: any chance you could kick off a release with the fix to cloud init18:31
Odd_BlokeMitchT: Well, we don't do releases for bionic, because it hasn't released yet.19:03
Odd_BlokeBut I have unblocked the daily, which was hung up on an unrelated issue.19:03
naccOdd_Bloke: can you make a note to yourself to sync ruby-delayed-job as soon as b+1 opens?19:18
naccOdd_Bloke: i'm syncing the other two i sponsored that are no-feature changes that took the same fixes as your uploads19:18
Odd_Blokenacc: Sure thing.19:22
naccOdd_Bloke: thanks!19:22
naccOdd_Bloke: debian went to a different upstream version, and it'19:22
nacc*it's not trivial to me if we'd need a FFe and that's probably not worth it :)19:22
MitchTOdd_Bloke I appreciate all the help.19:24
Odd_BlokeAgreed.19:24
Odd_BlokeMitchT: :)19:24
MitchTDo you think images will be created by April 10th19:25
MitchTones that work :P19:25
Odd_BlokeMitchT: The most I'm going to commit to is that we'll have images by release (i.e. April 26th per https://wiki.ubuntu.com/BionicBeaver/ReleaseSchedule).19:49
Odd_Bloke(But we will certainly have working images before that. :p)19:49
MitchT:)19:52
GoopAre there Oauth server packages for Ubuntu, or is Oauth just a concept, and you have to make your own application?20:23
dpb1Goop: OAuth is a protocol, there are most likely a lot of packages that implement that protocol for various purposes.  like, php, python, etc.20:34
dpb1not to mention many packages that need user login would make use of an OAuth provider to handle user auth, probably making use of those language-specific implementations.20:36
Goopdpb1, may I ask for help on implementing an authentication setup for my situation?20:55
dpb1probably beyond the scope of the expertise in this channel.20:56
dpb1but, you could certainly ask20:56
Odd_BlokeMitchT: The latest Azure image booted for me and was able to SSH in to it, FYI.21:32
rud0lfhello. is there an (un)official guide for newbie server admins? i know ubuntu itself as a desktop client, i know some about computers, i can script21:33
rud0lfall i need to know is how to secure and audit21:34
nacclol21:34
naccrud0lf: "all" :)21:34
rud0lftoo wide?21:34
naccrud0lf: that is a full-time position at most companies21:34
rud0lflol21:34
rud0lfi mean basics21:34
rud0lflike, giving someone shell account, restrict some binaries21:34
rud0lfexecutables, i mean21:34
rud0lfor how to parse auth.log and make it more verbose21:35
rud0lfnacc: consider me as a server toddler21:35
naccrud0lf: https://help.ubuntu.com/lts/serverguide/21:35
sarnoldrud0lf: I seem to recall thinking this was reasonable guidelines https://www.ncsc.gov.uk/guidance/eud-security-guidance-ubuntu-1604-lts21:35
naccbut if you're security-focused, i was going to ask sarnold :)21:36
rud0lfthank you, hop to my favorites (links, not you guys)21:36
Wolf_YHey guys22:08
Wolf_Yis anyone up i have some noob-ish questions about samba and ubuntu 17.10 networking22:08
dpb1ask away22:10
Wolf_Ydpb1:  alright so i am using ubuntu server 17.10 on hyper-v manager22:12
Wolf_Ydpb1:  i strugled with networking for a bit before i figured out that making a bridgeg connection between my host pc and hyper-v can help me set up a static ip on ubuntu server22:13
Wolf_Ydpb1:  so i did that and everything seemed to woek fine22:13
Wolf_Ydpb1: then i installed samba and added some folders with right permissions and when i try to access them from my host machine they work fine22:14
Wolf_Ydpb1:  when i try to transfer small files it works22:14
Wolf_Ybut when i try and transfer larger files the connection breaks22:14
Wolf_Yi think it has to do somethin with my net config22:14
dpb1yuck22:14
Wolf_Ydo you maybe have an idea22:15
dpb1anything showing up in `dmesg` or /var/log/syslog?22:15
dpb1(when the connection breaks)22:15
Wolf_Yim still quite new to linux22:15
Wolf_Yso would you like me to share the outputs22:15
dpb1well22:15
dpb1you can, but make sure you pastebin22:16
dpb1!pastebin22:16
ubottuFor posting multi-line texts into the channel, please use https://paste.ubuntu.com | To post !screenshots use https://imgur.com/ !pastebinit to paste directly from command line | Make sure you give us the URL for your paste - see also the channel topic.22:16
dpb1!pastebinit22:16
ubottupastebinit is the command-line equivalent of !pastebin - Command output, or other text can be redirected to pastebinit, which then reports an URL containing the output - To use pastebinit, install the « pastebinit » package from a package manager - Simple usage: command | pastebinit22:16
dpb1Wolf_Y: ^22:16
Wolf_Yalright ill use pastebin dpb1  what should i send22:16
dpb1`dmesg` and `cat /var/log/syslog`22:17
dpb1but first make sure you don't mind sharing the content22:17
dpb1it's likely fine if they are vms you are just testing with22:17
Wolf_Ydpb1:  im trying to make a media server22:17
Wolf_Ydpb1:  i supose i can share22:18
Wolf_Ydpb1: not quite sure how to coppy the output to clipboard22:19
Wolf_Ylooking into it right now, sorry for making it long22:19
dpb1Wolf_Y: use pastebinit22:19
dpb1dmesg | pastebinit22:20
Wolf_Yoh okay ill try22:20
Wolf_Yhttp://paste.ubuntu.com/p/2yjPPFYzTS/22:21
dpb1did you type that right?22:21
dpb1does not exist22:21
Wolf_Ylet me check22:21
Wolf_Yhttp://paste.ubuntu.com/p/ZyjPPFYzTS/22:22
Wolf_Ygot it22:22
Wolf_Ynow ill try it with the next one as well22:22
Wolf_Yhttp://paste.ubuntu.com/p/ZptqG7tkWs22:23
Wolf_Ydpb1: should i try causing the break and then do the error output again22:24
Wolf_Yclear22:24
dpb1Wolf_Y: ya, do.  and then just do     <command> | tail -100 | pastebinit    .... to only get the last 100 lines.22:25
Wolf_Yalright22:26
Wolf_Ytranfering the file22:27
Wolf_Yhttp://paste.ubuntu.com/p/vcv5fbrhnK//22:29
Wolf_Yhttp://paste.ubuntu.com/p/vcv5fbrhnK/22:29
Wolf_Yill do the other one now22:29
dpb1Wolf_Y: interesting22:29
dpb1Wolf_Y: what time did you initiate the transfer22:30
Wolf_Ya minute ago or so22:30
Wolf_Ywhat do you see22:30
Wolf_Yshould i do the dmesg as well22:30
dpb1run `date` on your server22:30
dpb1no22:30
Wolf_Yalright22:30
dpb1what does date say right no22:30
Wolf_Yone sec22:30
dpb1now22:30
Wolf_Ythe date says22:30
Wolf_Ycorrect date22:30
dpb1I want the whole thing22:31
dpb1:)22:31
Wolf_Yso the whole cat22:31
Wolf_Y?22:31
dpb1date22:31
Wolf_Yalright22:31
Wolf_Yhttp://paste.ubuntu.com/p/c4JqtFjzTV22:32
Wolf_Ythats date22:32
dpb1huh22:32
dpb1ok22:32
dpb1so nothing22:32
Wolf_Yso what do you say22:32
Wolf_Ywould you like the dmesg22:33
dpb1no22:33
Wolf_Yok22:33
Wolf_Yonce again, the smaller files and accessing the folder works just fine22:33
Wolf_Ythe permissions are 755 and 77722:34
dpb1unfortunately, the next thing I would do is a bit harder.  I'd switch samba into debug mode and do the same thing you just did.22:34
dpb1basically, start going through this22:34
dpb1https://www.samba.org/samba/docs/using_samba/ch12.html22:34
dpb1reproduce the problem, see if any interesting logs pop out22:34
dpb1if they do, I would probably take them to: samba@samba.org22:35
Wolf_Yi think ill just remove and once again try a fresh install22:35
dpb1that user list is very active22:35
Wolf_Yi now know how the server works22:35
Wolf_Yi just need to figure out the samba22:35
Wolf_Ythanks very much for your help, ill get back here tomorrow if fresh install does not help and try to debug samba22:35
dpb1k22:36
Wolf_Ysee ya then22:36
dpb1o/22:36

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!