/srv/irclogs.ubuntu.com/2014/12/05/#ubuntu-server.txt

bananapiethis is bad, all the defunct processes have parent process id of 1...00:00
bananapieand two /sbin/init running00:00
sarnold...00:00
bananapiesomething has gone terribly wrong on this server.00:01
sarnoldhmm, the second init might be a user session thing, I've got one of those too: init --user --restart --state-fd 2500:01
IronlennyI have a kvm vm that is using a macvtap bridge, but I cannot get an ip address from my network dhcp server. I'm running 14.0400:05
bananapieI rebooted the server. :(00:10
bananapiethis server has the worst uptime00:10
bananapie26700:10
bananapie267 days*00:11
=== Lcawte is now known as Lcawte|Away
IronlennyI have a kvm vm that is using a macvtap bridge, but I cannot get an ip address from my network dhcp server. I'm running 14.0400:48
=== zz_DenBeiren is now known as DenBeiren
=== markthomas is now known as markthomas|away
=== linstatsdr_ is now known as LinstatSDR
=== mfisch is now known as Guest45087
=== Lcawte|Away is now known as Lcawte
nivv_hey guys, how do I block this "user" to do stuff? root@databeredning08:32
nivv_what does the @ mean?08:32
lordievaderGood morning.08:46
lordievadernivv_: The 'databeredning' is the hostname of the machine.08:48
nivv_ah ok,08:48
=== nathema_ is now known as nath|off
nivv_When I try to do "iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT" I get "iptables: No chain/target/match by that name."08:58
nivv_how come?08:58
nivv_the input chain is present08:58
lordievadernivv_: Your kernel knows conntrack?08:59
lordievaderUbuntu kernels should by the way...08:59
nivv_lordievader, no idea,09:00
nivv_Do I need to install it?09:01
lordievadernivv_: What does "sudo lsmod|grep conntrack" return?09:02
nivv_lordievader, hold on, I'll check. The tech support says that my server is being hacked09:02
nivv_using up loads of network bandwidth so I can barley ssh into the machine09:02
nivv_not seeing anything on nethogs or iftop09:02
nivv_lordievader it returned nothing, blank line09:04
lordievadernivv_: Do you run the default Ubuntu kernel?09:06
nivv_"Welcome to Ubuntu 12.04.5 LTS (GNU/Linux 2.6.32-042stab062.2 x86_64)"09:06
nivv_Don't know if it's the default09:06
lordievader!info linux-image-generic precise09:07
ubottulinux-image-generic (source: linux-meta): Generic Linux kernel image. In component main, is optional. Version 3.2.0.72.86 (precise), package size 2 kB, installed size 32 kB09:07
lordievadernivv_: It ain't.09:07
nivv_it's a hosted vps09:08
lordievadernivv_: Your kernel either does not have conntrack compiled in or loaded as a module.09:09
nivv_ok, i tried doing "sudo apt-get install conntrack"09:09
nivv_but still get nothing when doing sudo lsmod|grep conntrack09:09
nivv_if I do conntrack -L09:11
lordievadernivv_: What happens when you run "sudo modprobe nf_conntrack"?09:11
nivv_i get conntrack v1.0.0 (conntrack-tools): Operation failed: Connection refused09:11
nivv_WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.09:11
nivv_FATAL: Module nf_conntrack not found.09:11
lordievaderAs I figured.09:12
lordievaderHate to break it to you, but custom kernels are not supported here. Running the default Ubuntu kernel solves your problem. However a workaround would be to use something other than conntrack.09:13
nivv_lordievader, thanks anyways! I really appreciate it. I don't even know what "sudo iptables -A INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT" means09:15
lordievadernivv_: Then it might be a good idea to learn that first ;)09:15
=== mfisch is now known as Guest3214
nivv_of course. But at the same time I'm being "hacked" according to the tech support09:15
nivv_so I don't really have much time09:16
nivv_:(09:16
lordievadernivv_: Drop everything but port 22?09:17
nivv_Yeah, I'm trying to implement this09:18
nivv_http://paste.jesse-obrien.ca/1c5S09:18
nivv_but I'm stuck on the first one09:18
lordievadernivv_: Do you have a backup way in, if ssh fails?09:18
nivv_no09:18
nivv_not that I know of09:18
lordievadernivv_: Since firewalls can lock you out very easily ;)09:19
nivv_maybe that's a good thing...seeing how clumsy I seem to be09:20
lordievadernivv_: You can skip the first line, it will make your firewall slower but for 3 rules you won't notice it.09:20
nivv_oh sweet09:20
nivv_here goes nothing then09:20
nivv_lordievader, this is the info I got from tech support, does it tell you anything? : http://paste.jesse-obrien.ca/1c6d09:23
=== Lcawte is now known as Lcawte|Away
nivv_wtf is "lrwkqgjsb"09:24
lordievaderCould be an exploit, is it still running? If so, kill it right now!09:25
nivv_how do I find it?09:27
lordievadernivv_: "ps aux|grep lrwkqgjsb"09:27
nivv_got this "albin     1103  0.0  0.0   9516   948 pts/4    S+   10:27   0:00 grep --color=auto lrwkqgjsb"09:27
nivv_now I can't do "sudo apt-get update"09:28
nivv_can't connect to the repos09:28
lordievadernivv_: Ok that is good. But still. Take a look at the other processes.09:28
lordievadernivv_: Did you also drop outgoing connections?09:29
nivv_https://www.dropbox.com/s/n2xgxdq605gl8qy/Sk%C3%A4rmklipp%202014-12-05%2010.29.17.png?dl=009:29
nivv_dump of the "sudo iptables -L -v"09:29
nivvlordievader, sorry got disconnected09:34
nivvdid you see anything wrong in the iptables?09:34
lordievadernivv: No, outgoing connections should be fine.09:35
nivvi flushed the iptables again and now it's working.09:35
nivvAnd when I add the rules again I can't connect to archive.ubuntu.com09:37
lordievadernivv: That doesn't make any sense...09:39
nivvfound this: http://serverfault.com/questions/121309/how-to-configure-iptables-to-use-apt-get-in-a-server09:39
nivvsee the top answer09:39
nivvmaybe has something to do with not using the first line?09:39
lordievaderCan you still perform dns lookups?09:39
lordievadernivv: You don't have a drop policy on the output chain.09:40
nivvWhen I add sudo iptables -A INPUT -j DROP it stops working09:41
lordievaderI do hope you have your "allow ssh" above it...09:42
lordievaderAnyhow can you answer my question?09:43
nivvi do it in this order09:43
nivvhttp://paste.jesse-obrien.ca/1c7c09:43
lordievaderCan you do dns lookups?09:44
nivvsorry for being ignorant, but how do I do that?09:44
lordievadernivv: "nslookup www.ubuntu.com"09:45
nivv-bash: nslookup: command not found :D09:45
lordievadernivv: sudo apt-get install dnsutils09:47
lordievaderIIRC09:47
nivvyup! thanks09:48
lordievadernivv: Does "sudo iptables -I INPUT 1 -m state --state RELATED,ESTABLISHED -j ACCEPT" fix your apt problem?09:58
nivvhold on, im on the phone with tech support09:59
nivv:)09:59
JediMasterhi, can anyone recommend any file change monitoring services? A client has recently had a wordpress installation breached and it wasn't obvious that it had been. The files were quite expertly altered, both PHP and javascript files.10:00
nivvlordivader, the tech support says that our server uses a massive amount of network bandwidth. Wouldn't I see that when looking on the activity in nethogs?10:00
nivvlordievader ^10:01
lordievadernivv: iftop would show you.10:01
JediMasterThe files were altered in such a way that the timestamp on the files did not change (I'm still not sure how they pulled that off in PHP), and the commands were hidden within multi-line comments that already existed and enough spaces added to the end of the line to hide it from common command line text editors10:01
lordievaderJediMaster: Zabbix can alert you of file changes, but I'm not sure if it will recursively parse through a directory if you give it one.10:03
JediMasterSo really we're interested in monitoring only a subset of file changes, not timestamp based detection but maybe md5sum checks and only for certain file types, e.g. php, javascript10:03
JediMasterlordievader, May the force be with you!10:03
lordievaderJediMaster: That's what zabbix does ;)10:03
JediMasterohh shiny, I already have zabbix clients on all the servers10:04
JediMasterI wasn't awear it could monitor file changes10:04
lordievaderJediMaster: https://www.zabbix.com/forum/showthread.php?t=2306110:04
JediMastera quick glance over that seems to suggest you need to specify files, there would be tens of thousands of PHP files to monitor10:05
lordievaderJediMaster: Like I said, I'm not sure if there is folder support...10:06
lordievaderBut there might just be ;)10:06
nivvlordievader, just hung up on the tech support of our hosting prodivder....they CONFUSED our IP with another scumbags IP10:07
nivvour server was never affected, it was another one in the same cluster10:07
JediMasterthe other problem is that we do updates to files nearly every day, so it'd be good if there was some way we could update the md5sums when doing an git pull/svn update10:08
lordievaderJediMaster: You could write a script that checks "git status" output ;)10:09
lordievadernivv: Doesn't take away that it is a good idea to have a firewall running.10:09
nivvlordievader, exactly10:09
JediMasterwell interestingly, the way we found it was an svn status10:09
nivvso I'm still gonna see to that, soon™10:10
lordievaderYou could even write a cronjob that simply makes sure that there are no uncommitted changes... ofcourse if an attacker notices this he (or she ;) ) will simply commit the changes ;)10:11
JediMasterthat had occured to me10:11
JediMasterboth points10:11
lordievaderI suppose you could block commits being made on production machines.. but that would likely be a hassle.10:12
JediMasterah, I forgot about tripwire, but I think that'll have the hassle of warning me about every legitimate change we make10:15
lordievaderA very ugly solution: put it in puppet :P10:18
=== Lcawte|Away is now known as Lcawte
jamespagegnuoy, "python-logutilsLiam Young <liam.young@canonical.com> (James Page <james.page@ubuntu.com>)" is showing up on my merge report - want to take care of that and I'll sponsor it for you?10:56
jamespagesemiosis, I also see glusterfs on the list of merges - are you going to pull in the version from Debian experimental this cycle?10:57
jamespagesemiosis, I'm guessing that might fixup alot of the feedback from the MIR review in 14.0411:02
gnuoyjamespage, sure, thanks11:02
acmehandleDoes anyone know if stackless python is in apt repositories?  I tried searching apt-cache and it doesnt seem so11:42
lordievaderacmehandle: Stackless Python, what is that?11:48
acmehandlehttp://www.stackless.com/11:49
lordievaderApt says about 'python3-greenlet': The greenlet package is a spin-off of Stackless11:51
lordievader!info python3-greenlet11:51
ubottupython3-greenlet (source: python-greenlet): Lightweight in-process concurrent programming (python3). In component universe, is extra. Version 0.4.2-1ubuntu1 (utopic), package size 12 kB, installed size 64 kB11:51
acmehandleExcellent.11:52
acmehandleDidnt know what to look for.11:53
acmehandleIts not going to replace the python3 I already have right?11:53
lordievaderacmehandle: It doesn't conflict with it.11:53
acmehandleOk, now that I installed it how do I invoke it?11:54
lordievaderacmehandle: No idea...11:54
acmehandleis it now part of python3 then?11:54
lordievaderacmehandle: No idea ;)11:54
acmehandleWhere can I find the readme for it?11:54
lordievaderacmehandle: I thought you knew the stackless thing ;) Anyhow apt-file will probably tell you what files it provides.11:55
acmehandleNope, just discovered it.11:55
acmehandlewhilst searching for an asynchronous webapp solution.11:56
acmehandleghetto gang banging rap music at 7am.  thats class.11:56
acmehandleNo, python3-greenlet is not stackless.12:00
acmehandlegreenlet is a module12:00
acmehandleIts not a python interpreter12:00
acmehandleNo, thats not at all what I want.12:02
=== Lcawte is now known as Lcawte|Away
nivvlordievader, you still here? :)12:52
nivvAnyone know of any alternatives to iptables?12:54
mardraumthere are lots of them. Do you need them to work on ubuntu or not? :p12:55
nivvhehe yea, my kernel doesn't have conntrack, and when I add some rules the dns lookup stops working :S12:55
nivvmarrdraum https://www.dropbox.com/s/3ge0czq84fbllgm/Sk%C3%A4rmklipp%202014-12-05%2013.55.48.png?dl=012:55
nivvthats my rules right now12:56
nivvand if I try a nslookup I get nothing :S12:56
mardraumperhaps you need an OUTPUT rule, like eg iptables -A OUTPUT -m state --state NEW,RELATED,ESTABLISHED -j ACCEPT12:58
mardraumI hate firewalling with iptables though, I would always replace it with something else if that were the purpose.12:59
nivvah, I found the problem. I needed to add the following rule: iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT12:59
mardraumyeah, you do need that13:00
nivv:))13:00
nivvmardraum the guide I was following was using conntrack, my kernel didn't have that so it threw an error13:02
=== bilde2910|away is now known as bilde2910
nivvhey mardraum, now I can't access the server via SSH13:03
nivvwtf13:03
nivvnevermind13:04
nivvworks now13:04
nivvphew13:04
lordievadernivv: So my guess was right ;)13:11
nivvlordievader, what were your guess now again? ;)13:12
lordievadernivv: By the by, it is better to put the RELATED rule as the first in the chain, not as the last.13:12
nivvyou mean "sudo iptables -I INPUT 1 -i lo -j ACCEPT" ?13:12
lordievaderFrom earlier: "nivv: Does "sudo iptables -I INPUT 1 -m state --state RELATED,ESTABLISHED -j ACCEPT" fix your apt problem?"13:12
nivvah shiet, I missed that lordie!13:13
nivvhttps://www.youtube.com/watch?v=l1dnqKGuezo13:13
lordievaderNo ^ that rule, that command puts it as the first rule.13:13
nivvah13:13
nivvthis is the rules I'm using now, in that order13:13
nivvhttps://gist.github.com/nivv/de0cf110131f830e37fc13:14
nivvshould I change anything from that?13:14
lordievadernivv: That is allways a difficult question to answer as I have no idea what your requirements in terms of service or security are.13:17
nivvI mean the order of the lsit13:18
nivvlist13:18
lordievadernivv: Line 6 could be replaced with a policy drop (-p DROP). But further more, I guess it is allright.13:19
nivvlike this "sudo iptables -A INPUT -j -p DROP" ?13:19
lordievadernivv: "sudo iptables -p INPUT DROP" But make sure you allow your services first ;)13:21
nivvyea :) what's the difference between -p and -j ? (sorry again if I'm being stupid)13:22
lordievadernivv: man iptables ;)13:22
Guest87920guys, anyone have any idea how is it even possible that ubuntu/other distros doesnt have smething like mageia control center?13:23
nivvah thanks, lordievader, really appreciate your help!13:23
mardraumGuest87920: maybe it sucks? what is it.13:24
lordievaderGuest87920: Mageia control center?13:24
Guest87920this http://doc.mageia.org/mcc/3/en/content/mcc-hardware.html13:24
lordievaderBlegh gui's...13:25
lordievaderYou have a command line, what's more to want?13:26
Guest87920lordievader: yea your grandmother is a perl monk to i suppose?13:28
lordievaderYou suppose wrongly.13:29
Guest87920mardraum: how can you assume something sucks if u dont even know what it is13:30
nivvGuest87920: he said maybe ¯\_(ツ)_/¯13:32
Guest87920nivv: mkay :D13:32
Guest87920nivv: all i meant to express was that if he saw word mageia ot doesnt mean it have to suck. Maybe its actually just the opposite. Who knows .. :D13:39
lordievaderTo each his own, eh ;)13:40
nivvI think he was trying to point out that it was impossible for us to know what you're talking about without a description of the software, which you gave immediately afterwards :)13:40
Guest87920:D13:40
JediMasterlordievader: ever come across "aide" looks something like what I want, but not quite13:41
lordievaderJediMaster: Never heard of it.13:43
Guest87920so nobody got even a slight speculation why it could be so that MCC havent already been ported to any other distro?13:47
Patrickdkheh?13:47
Patrickdkthis channel is about ubuntu-server, how would we know about other distro's? or about mcc?13:47
PatrickdkI would ask the #mcc channel about it13:48
jamespagezul, coreycb, gnuoy: can I get a +1 for inclusion of openvswitch 2.3.0 in the kilo CA please?13:48
jamespageditto for ceph giant once I have it in vivid13:48
zuljamespage:  yes go ahead13:48
lordievaderGuest87920: (Linux-)Server guys don't like gui's for configuring their servers...13:49
Guest87920oh right13:49
lordievaderGenerally at least.13:49
Patrickdkwindows server guys too :)13:49
Patrickdkwhy we have core-server for windows now :)13:49
lordievaderThe Windows admins I know still like to click around ;)13:49
Patrickdkyuk13:49
samba35is it possible to add ethernet card to system (want to add 1 more nic to system)13:50
Guest87920not on newer versions of it i suppose.. :D13:50
Patrickdkwe have deployed core server for most things, but a *few* apps still need the gui :(13:50
Patrickdksamba35, only if you have some place to plug it in13:50
samba35yes i have some free pci slots are there13:51
Patrickdkthen just pick one with a sane driver then :)13:51
Patrickdkmost cards will work13:51
coreycbjamespage, +113:51
samba35Patrickdk: can you please tell me which card do you recommand13:51
Patrickdkintel and stuff will be painless, broadcom will be more painful13:51
samba35ok thanks13:52
samba35bye for now13:52
coreycbzul, jamespage: ceilometer 2014.2.1 is ready for review - https://code.launchpad.net/~corey.bryant/ceilometer/2014.2.1/+merge/24379913:58
zulcoreycb: cak13:58
coreycbzul, too early for cake14:01
zulits never too early for cake14:01
coreycbzul, jamespage: cinder 2014.2.1 ready for review - https://code.launchpad.net/~corey.bryant/cinder/2014.2.1/+merge/24380314:08
zulcoreycb: lemme know when they are all ready for review and ill do it14:09
coreycbzul, k14:09
acmehandleI'm trying to install a deb pacakge using dpkg -i and am getting the following error:  unable to open file '/var/lib/dpkg/tmp.ci//control': No such file or directory14:15
acmehandlePlease advise14:15
jrwrenacmehandle: sounds like it is not a deb package?14:15
acmehandlejrwren: Its this:  http://www.stackless.com/wiki/Download   In the binaries section14:17
acmehandleThe 3.2 version installed.  Whereas me trying to install the 2.7 produced the above error14:18
jrwrenacmehandle: did you check the md5 ?14:23
acmehandlejrwren: md5sum checks out14:26
acmehandleI did a dpkg-deb -R went in to DEBIAN, apparently the control file is a ln -s to a non existent file.14:28
acmehandleWhereas when compared to the 3.2 package the DEBIAN/control file is its own file, not a link14:29
lordievaderacmehandle: Is the package made for Ubuntu?14:29
acmehandleDont know, its made for debian.  I installed the 3.2 version but it required tcl and tk dependencies to be resolved14:30
acmehandleStill, 3.2 installed without trouble14:30
=== _rsully is now known as rsully
lordievaderacmehandle: Then get one made for Ubuntu. Debian and Ubuntu are similar and yet they are different ;)14:31
acmehandleI dont think there is a stackless python made for ubuntu, only the derivative stackless module.14:31
acmehandleNot what I want.14:31
mardraumso use debian14:31
lordievaderOr compile from source.14:32
acmehandleSounds like I'll be compiling from source then14:32
lordievaderCreate your own package and throw it on launchpad.14:32
acmehandleOk, I'll compile, how would I create my own package though?14:32
acmehandleI've compiled before using configure14:32
acmehandlejust never created a package.14:33
lordievaderErr, I've only made packages to distibute code. Not binary packages... But google probably knows ;)14:34
acmehandleIndeed, the internet knows everything14:34
jrwrenacmehandle: maybe they have a source deb?14:35
jrwrenacmehandle: nope, I don't see a source deb :(14:36
jrwrenacmehandle: depending on why you want stackless, pypy may be an option.14:36
acmehandleits stackless mode, but not stackless14:38
=== mrosevzt1rk is now known as ropetin
=== Guest3214 is now known as mfisch
zuljamespage:  craaaap http://paste.ubuntu.com/9383355/15:02
jamespagezul: love it -https://launchpad.net/ubuntu/+source/ceph/0.87-0ubuntu115:21
jamespagefirst time that's ever happened to me with ceph...15:21
zuljamespage:  no problems15:22
zul?15:22
=== Lcawte|Away is now known as Lcawte
samba35how do i add psi-passtroth on ubuntu 14.04.1 with kvm15:44
=== MeltedDed is now known as MeltedLux
=== Lcawte is now known as Lcawte|Away
tewardwho has primary control over the serverguide documentation?16:21
tewardserver team or doc team?16:21
lakinGood morning folks, I'm running into some difficult to reproduce on command, but regular (a couple an hour) segfaults/aborts with apache2 on Ubuntu 14.04. I have some backtraces generated from core dumps, all seem to be crashes in libssl - I am fully up to date as of last night. How would I go about figuring out the cause of it?16:36
lakinstack traces are here: http://apaste.info/OBl http://apaste.info/FiK http://apaste.info/ptl http://apaste.info/q8X http://apaste.info/tjh http://apaste.info/Lc716:38
=== markthomas|away is now known as markthomas
jcastrogaughen, ping!17:20
gaughenjcastro, pong17:20
jcastrohi!17:21
jcastrowe got a bunch of new questions on openstack and the charms: http://askubuntu.com/questions/tagged/openstack?sort=unanswered&pageSize=5017:21
jcastrocan you ask people to take a look? I've tacked on some bounties as well17:21
jcastroroaksoax, there are maas questions piling up too17:22
roaksoaxjcastro: haha :)17:25
sarnoldlakin: has anything else been segfaulting? since the crashes are all over the place I kinda wonder if you've got some bad memory or something similar17:27
sarnoldlakin: I don't know the openssl internals well enough to know if the presense of ssl3 in all those methods means actual ssl3 or if they just never got around to renaming functions for TLS; it might be worth rechecking that you've got ssl2, ssl3 disabled if you can17:28
sarnold.. details on turning off ssl3 here: http://askubuntu.com/questions/537196/how-do-i-patch-workaround-sslv3-poodle-vulnerability-cve-2014-356617:29
uvirtbotsarnold: The SSL protocol 3.0, as used in OpenSSL through 1.0.1i and other products, uses nondeterministic CBC padding, which makes it easier for man-in-the-middle attackers to obtain cleartext data via a padding-oracle attack, aka the "POODLE" issue. (http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2014-3566)17:29
lakinsarnold: I believe we have turned off ssl317:53
lakinbut double checking now17:54
lakinConfirmed, SSLProtocol All -SSLv2 -SSLv3 is in our configuration17:55
lakinsarnold: thanks for your help, I have to leave but I'll be back once I'm at the office17:58
hariomWhat is the best way to transfer files (size less than 150 kb) to another server in secure and fastest possible way? As soon as file comes on Server A, I want it to send to Server B in secure way18:31
sarnoldhariom: there's a lot of options, you'll have to constrain the space a bit to get good answers. how many files per second? how far apart are the servers? why do you want the copies, what will the copies achieve?18:33
hariomsarnold: I need to send each file separately. Anywhere between 100 to 200 files per second (the max I can think I can get from clients). Servers are on LAN in a data center18:35
hariomsarnold: Each file is unique and not made available before18:35
hariomsarnold: Can NFS achieve that securely? or SCP/rsync etc?18:36
hariomsarnold: Are you there?18:38
sarnoldhariom: scp or rsync would have extreme trouble keeping up with 100 per second. NFS ought to be able to do that, as could ceph18:38
hariomsarnold: Can NFS be secured?18:40
ikoniadepends on your issues18:41
hariomikonia: like what?18:41
ikonialike why you think it's not secure, what your limitations are18:41
hariomCeph may have a learning curve. Never heard it before but seems very interesting18:41
hariomikonia: Sniffing18:42
ikoniasniffing what ?18:42
sarnoldit'd be worth spending two hours reading about ceph regardless if you ever use it or not, it's neat stuff18:42
sarnoldhariom: you could run nfs / cifs / ceph / whatever over IPSec or openvpn or something else if you wished; I don't believe NFS has any real privacy controls..18:43
LinStatSDRHello all.18:43
hariomsarnold: What if I create a socket client and server. As soon as I get a file, I read and send it to server. Socket server can have SSL18:57
hariomI suppose this will be quick, fast and secure?18:58
sarnoldhariom: the trick is that you'd need some protocol of some sort to identify filename, file size, build in recovery mechanisms if the connection stalls, etc.18:59
sarnoldhariom: it sounds simple at first but getting it right will take some effort18:59
hariomsarnold: I don't need file name and size as they are saved in db so remote server can access it from there.19:00
sarnoldhariom: but you need to know when one file stops and another file starts, right? :)19:02
hariomhmm... got your point19:03
hariomsarnold: base64 encode and send json string with filename :)19:04
hariomOverhead of encoding19:04
sarnoldhariom: hehehe, oof :) but that does sound like an option19:06
sarnoldhariom: maybe something like 0mq or protobufs can handle this; I really haven't looked at moving larger objects with those systems but they might be well-suited19:07
=== markthomas is now known as markthomas|away
=== sync0new is now known as sync0pate
=== markthomas|away is now known as markthomas
keithzg_Hmm, how do I tell where dnsmasq is getting its responses from? Trying to figure out exactly what's responsible for annoyingly long DNS reply lag on my network.21:22
keithzg_ex. any ping immediately resolves the correct address, but then pauses for a very long time before actually getting replies, presumably taking forever to perform the reverse lookup if I'm understanding it correctly.21:27
guntbertkeithzg_: *if* you have nm-tool:   nm-tool|grep -i dns21:38
keithzg_guntbert: hrmmm, that's interesting, nm-tool returns an IP address that is the expected DNS server, and running dig on arbitrary internal hostnames returns pretty much instantly, but pinging still has a long suspicious delay . . .21:45
=== NegativeFlare_ is now known as NegativeFlare
keithzg_I swear I was getting a long delay with dig when not specifying a nameserver earlier, but that appears to have vanished as a symptom now.21:47
guntbertkeithzg_: never heard of ping doing reverse lookups21:48
keithzg_guntbert: I'm probably getting the nomenclature wrong, but it's worth mentioning that there's no delay if I add -n as an argument21:50
keithzg_" -n     Numeric output only.  No attempt will be made to lookup symbolic names for host addresses."21:50
guntbertkeithzg_: you may be right, but as I said, I've never heard about that21:55
keithzg_guntbert: fair enough.21:55
keithzg_Hmmm and weirdly one of the suspect servers is responding to pings as hostname.local rather than just hostname or hostname.our.fqdn.21:57
Logos01keithzg_: What distro?22:29
Logos01Oh. ubuntu.22:29
* Logos01 needs to make a note of how many channels he's in22:29
Logos01keithzg_: regarding dig and not specifying a nameserver -- IIRC there was a bugged version of dnsmasq that had that problem.22:32
JediMasterlordievader: I couldn't find something that did exactly what I wanted to monitor the website files for changes, and in the end I wrote a program to do it for me =)22:53
keithzg_Logos01: Huh, that'd be quite the unfortunate coincidence, heh.22:53
Logos01JediMaster: inotifywait22:53
JediMasterLogos01, not realistic with half a million files22:54
JediMasterpossible but silly22:54
Logos01Depends, really -- it works on system calls in the filesystem...22:54
JediMasterit'd take 0.5GB of ram to monitor that many files22:54
JediMasterand it's non-paged kernel memory too22:55
* Logos01 shrugs -- that's not a huge investment tbqh22:55
JediMastertrue, but this only took an hour or so to write22:55
acmehandleIs there a way to reverse an apt-get install with its dependencies?  For example if I installed tcl8.5 and its dependencies is there a way to reverse that?  So I dont keep dependencies I dont want until I really need them22:55
Logos01JediMaster: There's already shell utilities that operate on that syscall so you'd be able to do something similar in about that much time.22:55
JediMasterlordievader: it catalogues all the files of certain types (e.g. .php, .js etc.) md5sum's them all, checks against the previous run, looks for files that are new, files that have been deleted and changes. It then checks if they're in SVN, if so it shows an SVN diff if they're not just updated22:55
Logos01I mean, what did you do in lieu?22:55
JediMasterLogos01, I did try some of them out, they all failed after the OS'es default 8k monitor limit, easily changable of course, but it couldn't do all of the above with svn integration etc. so figured I might as well do it myself22:57
JediMasterthey also had limits such as not being able to monitor certain file types recursively through a tree22:57
JediMasterI did it in 67 lines of code (with comments) in the end, so not too worried =)22:58
JediMasterprobably more like 30 lines in total22:58
Logos01"not being able to monitor certain file types recursively through a tree" <-- curiously I didn't experience the same when I had to work with the realtime transfer of newly created pdf and xml files (but not any other filetypes)22:58
Logos01Granted I had more lines than that, but I also did more things than just transfer the files...22:59
JediMasterLogos01, what did you use in the end? 30 lines includes all the monitoring too22:59
JediMasterof course, it does mean running md5sum over all the files each time it's run, but it's suprisingly fast, only takes 2 seconds to run23:00
Logos01inotifywait.23:01
JediMasterI also didn't fancy keeping a script running all the time for inotify to tell it something had changed23:01
qmanLarge scale inotifywait works really well IME23:02
qmanI recently wrote a script as a bandaid to netatalk permission failure on a massive web directory23:03
=== bilde2910 is now known as bilde2910|away
qmanI had to increase the limits in sysctl, but it works great23:04
JediMasterstill rather think that the kernel memory could be better used than 0.5+GB being used for it though23:04
JediMasteralso, I didnt' really want to have an email sent out each time it was triggered, as we often upload 100+ files in one go via svn/git update23:04
JediMasterat least with running the script every 5 minutes it catches it in one bulk email, and if it's comitted changes it's a lot less verbose23:05
JediMasterI'm sure if you need instant notifications it's much better23:06
qmanIn my case it runs a chmod and chown every time a file is created/modified23:07
qmanBecause despite netatalk having parameters for that sort of thing, they don't actually work23:07
JediMasteryeah so effectively one or only a few lines of scripting needed23:08
JediMasterthis needed a fair bit of logic to decided if to bug people about changes23:08
Logos01JediMaster: In my case I needed to set up a realtime file transfer process.23:11
Logos01My whole script is only about 55 lines and I introduced some extra logic on top of that.23:11
Logos01My fileset is only in the mid 4 digits low 5 digits though.23:11
xcyclistCannot find doc on the two zeros at the end of:  192.168.X.X:/path/to/nfssharefolder             /media/nfs-foo     nfs     _netdev,defaults,user,auto,noatime,intr   0 023:14
xcyclistin this example fstab line.  I just need to find the right doc.  man fstab doesn't do it.  Perhaps an online doc I have not yet gotten to.23:15
sarnoldxcyclist: man 5 fstab, look for fs_freq and fs_passno23:15
xcyclistNever mind.  I got it on the wiki.  Sorry guys.23:16
Logos01xcyclist: Oh. Those deal with the frequency at which a filesystem is fscked, and when it is fscked, upon boot.23:21
Logos01As sarnold said, fs_freq and fs_passno in fstab are your keywords. :)23:22
xcyclistThank you.23:40
xcyclistI don't see addr= as an option in any of the documention, but my spec uses it.  Is this just a mistake, or am I looking at the wrong docs?23:41
xcyclistI do see clientaddr=, but not addr=23:41
sarnoldxcyclist: you may only see errors if you try "mount /media/nfs-foo" and let mount look it up from fstab..23:44
sarnoldxcyclist: .. and even then you may only see errors in the logs rather than at the terminal23:44
xcyclistI found something about it in this doc:  http://wiki.linux-nfs.org/wiki/index.php/NewMountDesignSpec, but pretty weak.23:46
xcyclistsorry sarnold.  I am sure that will help me, but I am still rather weak myself in context on this.  Any elaboration you can make would be appreciated.23:47
sarnoldxcyclist: interesting; addr= is clearly documented there, but they never say what it does or why. that's annoying.23:51
=== MeltedLux is now known as MeltedDed

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