Tag Info

New answers tagged

0

Theoretically you could write your own. The password in /etc/shadow is generally just a hash, the type of which can be defined in your /etc/pam.d/ configuration. Hash a new password, stick it in /etc/shadow, and you've just changed the user's password. Much much more information on the hashing/encryption of passwords and how to programmatically modify ...


10

You can do yum whatprovides <path> to see what package provides a file. For example, yum whatprovides /usr/bin/top will tell you for top or yum whatprovides '*/top' if you weren't sure of the path.


5

The "top" utility is usually in the "procps" package.


4

My guess was that you hit this bug: http://bugs.centos.org/view.php?id=7669 , but I don't see mod_gnutls in your loaded modules. Nevertheless, to me it seems like you've hit some kind of bug. As I can see, you don't use the latest httpd version, so you should first try and update your httpd package: yum update Please restart your httpd afterwards, then ...


0

Install xdebug and turn on profiling. Then use a utility like wincachegrind or kcachegrind to drill down to see what's taking the time. Check out http://www.xdebug.org/docs/profiler for more info.


1

If you look at the files in directory /etc/pam.d/ you'll (almost certainly) find one or more of them that refer to pam_pwdfile. The following command will show you which ones ... grep pam_pwdfile /etc/pam.d/* From this you should be able to work out (from the file name) which bit of of the system is trying to use pam_pwdfile for authentication.


0

You need to do this on web server. Try with a reverse proxy Original post: http://www.jamescoyle.net/how-to/116-simple-apache-reverse-proxy-example


3

This is probably a SELINUX-related problem. Try the following (in preference order): setsebool httpd_can_network_connect_db on If it works, make it permanent using the "-P" flag. If it does not work, go to step 2: setsebool httpd_can_network_connect on As above, if it works, use the "-P" flag. Otherwise, go to step 3: setenforce 0This will put SELINUX ...


0

I was just 30 minutes too early posting this question. There was a SELinux variable I didn't know of: httpd_can_network_connect. Setting this on solved the problem :)


0

I have a feeling you may not like this answer, but THIS answer includes some insight none of the others consider. . . You write: I always used the command: shutdown -r now However, sometimes that causes MySQL issues. The problem here is NOT your method of shutdown, is the piece of software that can't handle a shutdown properly; MySql. The ...


0

You have a couple of options here, you can specify commands that can be executed in the authorized_keys file (if you are using public/private keys) Here is an article which talks about this method: http://cybermashup.com/2013/05/14/restrict-ssh-logins-to-a-single-command/ The second way to skin this cat is to give the user account a restricted shell. In ...


16

yum keeps its own history, so you can find out when a package was installed or updated using its history. For instance, yum history packages-info ruby will give you all the transactions involving ruby, where the oldest one is usually the one where the package was installed. Transaction ID : 102 Begin time : Thu Apr 3 17:15:17 2014 Package : ...


6

You can remove them with yum autoremove.


2

Filesystem should be fine. You'll probably have some gaps in log files and it's possible that scripts/programs that aren't scrupulous about checking the success of writes may have lost data but that's all. You might want to check that logging (apache and syslog) is working correctly after you fixed the space problem - a service reload should be all that is ...


0

An aliased interface is really just a secondary address on the original interface the alias was created from (see how there are no packet counters for lan1:1). As such you can't create VLAN sub-interfaces on it. What you can do is create aliases or add secondary addresses to a VLAN interface.


0

It worked by specifying the port number along with the IP Address: vncviewer IPAddress:5901


2

If mysqld is running (check your process table), you should probably stop it via a kill command (dont use kill -9 as that will do an un-graceful stop of the service). When mysqld is no longer present in the process table, start the service normally.


0

Blocking access to the xmlrpc.php will lower the cpu usage. I've experienced this same attack, and although the attacker(s) were hitting other pages, blocking their access to xmlrpc.php made the site usable again. if you are running apache, you can place the following in your .htaccess for WordPress: <Files xmlrpc.php> Order Deny,Allow Deny ...


0

What are you trying to achieve? It looks like the router is your DHCP server giving out on 10.0.0.0/24 is that right? Do you have port forwarding setup on the router to your internal devices, you will need to NAT the external traffic based on port (dst/src).


3

It looks like you're getting hit by a pretty standard brute-force password guessing attack against Wordpress. As the linked article says, There are many ways to block brute force attacks. If you have a dedicated server, you can install OSSEC (open source) on it and let it automatically block the IP addresses that miss too many passwords[...] ...


1

CentOS doesn't provide PHP 5.5 in their standard repositories Look here; you'll need to use EPEL https://webtatic.com/packages/php55/


0

Tested on Centos 7(6?) in /etc/fstab: //win_server/share /mount cifs credentials=/etc/cred.cifs,nounix,nobrl,noperm 0 0 On Centos 5 //win_server/share /mount cifs credentials=/etc/cred.cifs,nounix 0 0


1

I'm not that familiar with lsyncd, but judging from the man file -log scarce should be added to the start-up script /etc/init.d/lsyncd daemon $lsyncd -log scarce -pidfile $pidfile $config I would also recommend adding /var/log/lsyncd/lsyncd.log to logrotate. Create /etc/logrotate.d/lsyncd with following: /var/log/lsyncd/*log { missingok notifempty ...


0

You can do this inside the authorize section authorize { if (!(LDAP-Group == '<group name>')) { reject } } Group name can be a name, or DN. In version 2 the heuristic is pretty simple, it just checks for the presence of a comma to determine if its a DN.


0

I logged in to another account, and found out that the whole 'admin' directory belonged to group 'nginx'. I simply added 'admin' to that group, and the world is nice again!


-1

#> iptables -I INPUT -s 66.230.160.1 -j DROP #> iptables -I INPUT -s 66.230.160.15 -j DROP


0

There are at least a couple ways you could achieve that. I've seen examples of using iptables with its string/bytes-matching functionality to look for recursive queries coming from outside, and then dropping them. I've a colleague that did that on an authoritative non-recursive server for a number of years and he said it works well. I've also seen people ...


1

I did not researched the issue throughly, so I do not understand the details, but it seems this has something to do with how the active - passive connections are setup both for vsftpd on the server and for the client (ex: Filezilla). Basically you will need to: configure vsfptd passive mode by adding the following to /etc/vsftpd/vsftpd.conf: ...


3

This network card is ancient and the sundance driver is no longer supported in EL7. The drivers given by the network card vendor are for a much older version of the kernel and are unlikely to work on modern systems. Just go get a $10 gigabit NIC, before you have spent much more than $10 in labor costs trying to make this work.


0

They are packaged by different maintainers and may conflict in the sense that they provide the same files etc, and possibly mysql rpm:s from official repos will not consider themselves upgrades of the mysql rpm:s installed from remi. I think dump the databases, uninstall all mysql rpm:s from remi repo, disable remi repo, yum clean all, install mysql from ...


0

Try to run "restorecon -RF " and restart MySQL service. If this does not work, try to set SELINUX into permissive mode by using "setenforce 0". If that work, your SELINUX policy need some other changes.


1

Boot to just a command line by adding init=/bin/bash to the kernel arguments in the boot loader. Open a shell in a new VT by typing openvt -- /bin/bash Continue the original boot sequence by typing exec /sbin/init in the first bash shell. Once the boot sequence stall you can switch to the shell opened by openvt and start collecting information about the ...


0

A regular system-wide crontab is a specific user's crontab and it has the username field, as used by /etc/crontab. Using scripts in /etc/cron.* (hourly, daily, weekly, monthly) is a cleaner and easier way (prevents common syntax errors) of configuring crontab for root user and this is handled by run-parts which run scripts or programs in a directory. All ...


2

It can be a problem related to packet size and latency. Try the following: enable jumbo frames (MTU >= 9000 bytes) on both machines use UDP or, alternatively, manually increase TCP window size on both machines The report back your results.


0

This will install the package ignoring dependencies but automatically looking up the download URL from your repositories. rpm -Uvh --nodeps `repoquery --location winswitch` When updating, you can do the same command before doing a "yum update" so that winswitch will be properly updated.


1

Cronjob for both log & email : Run once a month at midnight of the first day of the month: 0 0 1 * * 0 0 1 * * /home/User/script.sh > /home/User/cronlog/`date +\%Y-\%m-\%d-\%H:\%M:\%S`-cron.log 2>&1 ; mailx -s "CronJob is run successfully" someone@domain.com,someone1@domain.com


1

Well, I would start off with the naive approach like so: $ top |grep %pid On ubuntu 12.04, it outputs the line for the PID once per update of top: username@usrver / $ top |grep 2593 2593 username 20 0 1103m 170m 16m S 30 2.2 67:25.38 chrome 2593 username 20 0 1103m 170m 16m S 28 2.2 67:26.24 chrome 2593 ...


0

Now with the changed topic, this becomes a question for iptables. What I currently use (in overly simplified form) is: iptables -I INPUT -m tcp -p tcp --syn --dport 80 -m connlimit --connlimit-above 20 -j LOG --log-prefix "DoS Filter(connlimit): " iptables -I INPUT -m tcp -p tcp --syn --dport 80 -m connlimit --connlimit-above 20 -j DROP obviously you may ...


3

I got that to work by adding my user to the systemd-journal group: sudo usermod -a -G systemd-journal bob bob is now a member, log out, log in and: id -a bob uid=1000(bob) gid=1000(bob) groups=1000(bob),190(systemd-journal) And now it works: $ journalctl -- Logs begin at Mon 2015-04-06 09:50:36 BST, end at Thu 2015-04-09 20:20:16 BST. -- Apr 06 ...


1

The overall question is fairly broad, but I'll focus on your specific asks: Is it possible to have a directive for each directory in the httpd.conf? Yes, it is possible. Is the above better than placing .htaccess files in each application directory? They serve different purposes. <Directory> administratively defines ...


0

You're trying to install packages meant for EL6 onto EL7. This will not work and there is no way to make it work. They are not compatible. If you really want to run an old Varnish version, then use EL6 to begin with. The version of varnish included with EPEL for EL7 is 4.0, so it is not likely there will ever be 3.0 built for EL7.


0

On your system (Centos 6.5 kernel 2.6.32-431) ipmi_si module is not present because it's built-in in the kernel. Double check with the following command: [root@host ~]# cat /proc/kallsyms | grep init_ipmi_si ffffffff814fb086 t init_ipmi_si ffffffff81d26f50 t __initcall_init_ipmi_si6 init_ipmi_si is the initialization function of the ipmi_si module. Same ...


0

Spacewalk free upstream community project of the Red Hat Satellite. You may use it to manage CentOS servers.


0

Your httpd.conf would look like this to reverse proxy the Jenkins. VirtualHost *:80> DocumentRoot /var/www/html ProxyPass / http://localhost:8080 / nocanon ProxyPassReverse / http://localhost:8080/ ProxyRequests Off ProxyPreserveHost On <Proxy http://localhost:8080/*> Order deny,allow Allow from all </Proxy> ...


0

With both the old & new drives attached, issue the following command to dump the DB on the read-only disk: mysqldump --all-databases --create-options -u root -p > /tempdir/dump.sql where /tempdir/ is a temporary directory on the new (read-write) disk. From here, you can reimport your data on the new MySQL instance by using the following command: ...


0

In /etc/ssh/sshd_config add the group of your user to AllowGroups. Restart sshd service sshd restart


0

Use CentOS OpenLDAP help page. It is very concise and no fluff. Prior to doing so - please revert all the config files to their original state. Can be confirmed via: # rpm -V openldap-server If above command shows any files modified - either remove and reinstall openldap-server or fetch files over from backup.


0

I had the same issue a while back. In my case I got 126 without the execution bit set and 127 with the bit set. I later figured out it was related to some shared libraries missing on the system. Even if the binary is linked statically it seems to use some shared libraries from the system. I don't really remember which libraries were causing the problem, ...


0

as it has been already identified - this error pops up with any issue while setting up network: IP conflict, routing issues, etc. Look at your gateway settings to confirm your gateways are set properly and things are what they need to be with /etc/syscofig/network and each of the /etc/sysconfig/network-scripts/ifcfg-* look for duplicate IP, routes set via ...


0

A failure to get an IP from DNS will also give this error as I have just found. In fact it looks like any error with networking will cause this error. This appears to be a problem with CentOS 7 in that it gives a very poor error here.



Top 50 recent answers are included