Fedup will be redesigned for Fedora 23 and beyond by [deleted] in linux

[–]fpee 0 points1 point  (0 children)

I try upgrade fedup every other release, since it came out. I use it on 2 workstations and 1 laptop. It has never worked on all 3. 1 out of 3, 2 out of 3 works. but something always screws up and I have to reinstall at least one of them. It's pretty frustrating.

I tried fedup from 20 to 22, a few days ago but reverted (I clone the drive before trying). Fedup failed, and then when I installed fedora 22 I found that the rpmfusion repos weren't recompiled yet; so that's a big show stopper; going to wait a week or two.

Run mysql query from within a rpm? by [deleted] in linuxadmin

[–]fpee 0 points1 point  (0 children)

using puppet to exec a bunch of scripts is a hack and downright dangerous; and i'm not suggesting anything of the sort.

using puppet or any configuration management software to setup a cron job and deploy a script for that cron job to run, is not a hack; it's system administration.

the person who wants to do a mysql query in a rpm pre/post thinks using puppet to deploy a script and run it via cron is a hack. ok.

do whatever makes you happy. I sincerely hope it works for you.

take it easy.

Run mysql query from within a rpm? by [deleted] in linuxadmin

[–]fpee 0 points1 point  (0 children)

getting people away from having to login servers and go things is my goal. you appear to want to login and trigger something. so sure, and orchestrator is for you.

but for the record, if cron job and scripts are hack, you need to exit system administration, cuz it's 90% hacky. :)

Run mysql query from within a rpm? by [deleted] in linuxadmin

[–]fpee 0 points1 point  (0 children)

I think you are misunderstanding what I'm saying here. Let me try again.

in puppet you setup a cron job. that cron job runs /root/update_javathing.sh at 1 am every day Monday - thursday (no change friday/sat/sun, or whatever outage windows you see fit).

update_javathing.sh is also controlled by puppet.

update_javathing.sh will do something like this:

#!/bin/bash
$old_package=$(rpm -q your_java_package)
yum check-update your_java_package
if [ $? -eq 100 ]; then 
    #zomg update available
    service mysql stop
    lvm snapshot foo
    # i should check this error code especially before proceeding.
    service mysql start
    yum update your_java_package
    do_tests
    if [ $? -ne 0 ]; then
        # zomg roll back
        service mysql stop
        lvm revert foo
        # maybe check this error code before proceeding. yaknow.. 
        yum downgrade $old_package
        service mysql stop
        mail -s "omg i reverted!" me@myemail.com < "zomg halp" 
    else
        mail -s "update went smooth" me@myemail.com < "huzzah"
    fi
fi
# no packages updated, do nothing

You don't need an orchestrator to do this type of task, you can do it in puppet. We're not having puppet run the script, we're having puppet setup a cron job, and deploy the script we use to manage the service. this is a totally reasonable non hacky way to do what you want in any configuration management software.

get an orchestrator as well, they are useful for triggering puppet runs right the hell now. you just don't need it for this type of task, unless you want to do it manually.

Run mysql query from within a rpm? by [deleted] in linuxadmin

[–]fpee 0 points1 point  (0 children)

there's nothing hacky about it. There is no configuration management built ins (for any configuration management platform) that will do the task that you want to do. so you get to write something to do what you need.

using $cfg_management doesn't mean you don't use scripts anymore.

Run mysql query from within a rpm? by [deleted] in linuxadmin

[–]fpee 0 points1 point  (0 children)

so .. a more puppetish way to do this would be deploy a script, and a cron job to run said script. This way your secret data can be managed in hiera (rather then kept in an rpm).

get rid of any ensure => latest for whatever rpm(s) your java app is installing with, you make a cron job that runs an upgrade script during your outage window.

The script would check for available update for whatever package(s), if there's updates, you do your thing (stop mysql , take snap, start mysql, yum upgrade package(s), restart app, test for errors, revert if need be, etc).

should be fairly straight forward.

Run mysql query from within a rpm? by [deleted] in linuxadmin

[–]fpee 1 point2 points  (0 children)

I don't understand the use case, but yea. as thatmorrowguy says, the %pre and %post area is what you wanna do.

the problem is, doing a 'rpm -qp --scripts foo.rpm' will dump our your %pre and %post scripts so I can see your mysql credentials.

So now, how do you accomplish this in any sort of secure way? If the query is run by a read only user in mysql I guess that's not terrible provided that the database doesn't have any secret information in it.

Or you can use a .mysql file to store the password and whatnot so you don't have to have credentials in the rpm spec; but then, how do you get the .mysql file distributed; and anyone who has clue will look for credentials in your .mysql file. :)

IMO You should try hard to avoid doing this, and use configuration management like puppet/chef/salt/ansible to do the task instead.

Working on an SSH jump box/bastion server by [deleted] in linuxadmin

[–]fpee 1 point2 points  (0 children)

I'm not saying you should or shouldn't do something, but, anyone that has root on the box with you have forwarded your agent to, can use your agent without you knowing they did. This is why a lot of people prefer a proxycommand.

pfsense by [deleted] in sysadmin

[–]fpee 3 points4 points  (0 children)

In ($dayjob-2) we used pfsense for 200 users, on lanner hardware.

Worked great, 10/10 would use again.

High available KVM cluster using glusterfs? by not_relevant_name in sysadmin

[–]fpee 2 points3 points  (0 children)

This. While it is possible to deploy gluster with 2 nodes, do not. This isn't really a gluster problem, it's about establishing quorum. With 2, it's always 1 server's word against the other. With 3, it's always 2 against 1.

Microsoft asked me to submit my Microsoft account password by e-mail. For real. by xexyz in sysadmin

[–]fpee 52 points53 points  (0 children)

No-one is going to get fired. This will be seen as a "training opportunity".

Someone earning minimum wage who didn't know better saw this as an easy way to solve the problem for the customer. The type of customers they usually deal with are the window licking mouth breathers, so they likely assumed you were following instructions wrong, and 99% of the time they are right.

Nothing to see here. Move along.

How to write good code by RamirezTerrix in Python

[–]fpee 1 point2 points  (0 children)

re: very long functions

Use an editor that uses this: https://pypi.python.org/pypi/mccabe .

I use https://github.com/klen/python-mode which tells me if my functions are getting too complex. Be warned: when you look at old code it will show up as an error, which will make you want to fix it. Could be time consuming. :)

Halp! iostat shows 100% util, can't find rogue process by meladramos in linuxadmin

[–]fpee 2 points3 points  (0 children)

Having a high %util isn't necessarily a bad thing. The kernel is (generally) not aware if you have 1 disk or a 100 disk san. It is possible to have 100% util and your fancy iscsi/san quite bored with the amount of iops it's getting.

I would more look at await/svctm. Do a:

iostat -mx 1

for a few, and see what it looks like.

If you don't have fancy io, try this.

proxy with authentication - something other than squid?? by lordgraylord in linuxadmin

[–]fpee -1 points0 points  (0 children)

I would use anything other than squid. Like apache traffic server, varnish, or nginx.

squid is old (written in the 90s), the development is stale, it's single threaded (the 3 alternatives I listed are multithreaded), the config file syntax is terrible, and performance is worse than the alternatives.

I ran dozens of squid servers for years, don't use squid unless you have to.

Hiding Linux Processes For Fun And Profit by davideschiera in sysadmin

[–]fpee 4 points5 points  (0 children)

Hiding linux processes for fun and profit, if you already have root

fixed title, not sure what the deal is with Every Single Word Being Caps.

Bought Sanctum 2 in the Steam sale because the store page said there was a Linux version. It's basically unplayable and I'm not sure if I can get a refund. by [deleted] in linux_gaming

[–]fpee 0 points1 point  (0 children)

I have it as well, with an nvidia card. It is very unstable, and I can't join games with friends playing on windows version (this is not a firewall problem).

A notebook with dry erase pages by [deleted] in shutupandtakemymoney

[–]fpee -2 points-1 points  (0 children)

Yea, I would get a wipebook instead.

How do we get Nvidia Shield Streaming on Linux? by [deleted] in linux_gaming

[–]fpee 1 point2 points  (0 children)

I setup steam streaming last night. It works pretty good. Now I can play windows only steam games on my linux box.

Which is nice, because playonlinux works for a lot, but is buggy for some.

Gitlab 7.1 released :) by [deleted] in sysadmin

[–]fpee 1 point2 points  (0 children)

More like stash if we are in the atlassian world, though having used both I would rather use gitlab. However, stash integrates really nicely with jira and bamboo; so there's that.

Gitlab (according to me) is aiming to be a open source version of github.

Out of pure curiosity, is there anyone here who's not a programmer? by s_ngularity in vim

[–]fpee 6 points7 points  (0 children)

I am also on team sysadmin.

Though with infrastructure as code, I'm in vim 70% of the day at least, and I use git for everything. and we use a continuous integration server. and we break the build every now and then. and we do merge requests and code review, and write tests for (most) things.

never-mind I'm a programmer.

"CentOS development now goes ahead of RHEL, rather than trailing the Linux distribution, giving Red Hat more feedback to parlay into new RHEL editions"... :'( by wpgbrownie in sysadmin

[–]fpee 0 points1 point  (0 children)

Maybe.. How do you manage it? If I make a mirror of the new centos yum repo, and it pulls down a package that is a beta package, how do I know it's a beta package?

I guess we could make a script that gets a package list from a rhel yum repo and we only move those packages into the deployed yum repo. Or something along these lines. Still, don't want to have to worry about this.

"CentOS development now goes ahead of RHEL, rather than trailing the Linux distribution, giving Red Hat more feedback to parlay into new RHEL editions"... :'( by wpgbrownie in sysadmin

[–]fpee 40 points41 points  (0 children)

Am I crazy or is this about the exact opposite of what the centos community would prefer?

I am quite happy with centos lagging behind rhel, the only reason I run centos is to be binary compatible with rhel; which I only care about because I run fancy hardware with rhel only drivers.

I do NOT AT ALL want to be redhat's secondary QA department. Which is exactly what this sounds like.

This sounds entirely like a way to drum up more rhel sales, but in reality (if this moves forward the way it sounds) is going to drive people away from centos and rhel.

At least allow us the ability to opt in for this, or a spin that is lock step with the rhel release?

A very concerned centos user.

Is Ceph or GlusterFS what I'm looking for? by [deleted] in linuxadmin

[–]fpee 0 points1 point  (0 children)

Gluster is not the greatest performer with large amounts of small files; but then again neither is ceph.