modprobe ipmi_devintf
modprobe ipmi_si
Monthly Archives: December 2015
scp port
scp -P 2222 …
Briefly unavailable for scheduled maintenance. Check back in a minute. wordpress
Go to website public_html and delete .maintenance file.
kde restart kde panel
kbuildsycoca5 && kquitapp5 plasmashell && kstart5 plasmashell
postfix read mail in queue
postcat -q MESSAGE_ID
smartctl check megaraid
smartctl -a /dev/sda -d sat+megaraid,6
sentora reset zadmin pasword
This will reset admin password:
setzadmin --set new_password
python scan IP range
import sh
print "Scanning..."
# ping range 8.8.8.7 - 8.8.8.9
for num in range(7,10):
# declare ip address
address = "8.8.8." + str(num)
# check if host is alive using PING
try:
# bash equivalent: ping -c 1 > /dev/null
sh.ping(address, "-c 1", _out="/dev/null")
print "ping to", address, "OK"
except sh.ErrorReturnCode_1:
print "no response from", address
cpanel delete all user email accounts
“popaccts” option and is not enabled on your account
for i in `\ls -A /home/user/mail/domain.com/`; do /usr/local/cpanel/scripts/delpop "[email protected]" ; done
munin fix zoom cpanel
cat /usr/local/apache/logs/error_log | grep munin-cgi-graph
cpanel skip spf check for ip range
Go to WHM
Go to "Exim Configuration"
Go to the "Advanced Editor" tab
Scroll to/locate the section labeled "spf_bl (Reject SPF failures)"
If it is checked, uncheck it (this disabled the default SPF behavior)
Make sure the section just above it labeled "custom_begin_mailauth" is checked (enabled) and paste the below snippet in the text box:
deny
hosts = ! +backupmx_hosts
message = SPF: $sender_host_address is not allowed to send mail from $sender_address_domain
spf = fail
qmail spfbehavior
cat /var/qmail/control/spfbehavior
0 to disable.
1 selects ’annotate-only’ mode, where qmail-smtpd will annotate incoming email with Received-SPF fields, but will not reject any messages.
2 will produce temporary failures on DNS lookup problems so you can make sure you always have meaningful Received-SPF headers.
3 selects ’reject’ mode, where incoming mail will be rejected if the SPF record says ’fail’.
4 selects a more strict rejection mode, which is like ’reject’ mode, except that incoming mail will also be rejected when the SPF record says ’softfail’.
5 will also reject when the SPF record says ’neutral’.
6 if no SPF records are available at all (or a syntax error was encountered).
Error: Cannot retrieve metalink for repository: epel. Please verify its path and try again
sed -i "s/mirrorlist=https/mirrorlist=http/" /etc/yum.repos.d/epel.repo
iptables save centos 7
/usr/libexec/iptables/iptables.init save
iptables: Saving firewall rules to /etc/sysconfig/iptables:[ OK ]
kill tty session
w
ps -ft pts/1
kill -9 PID
or
skill -KILL -v pts/1