myce

Well-Known Member
Oct 24, 2001
46
0
306
Almost a year ago, I upgraded my RackShack (EV1) server. Prior to that, I never had any problems with my IP address pool. But shortly after my new server was brought online, it was hacked/rooted, and EV1 had to restore it for me. At the time, I was told that EV1 support was having to "manually" reload cPanel due to a bug in their automated restore scripts. And, ever since the restore, I have had a problem with the IP address pool turning "red" within WHM anytime the server is rebooted. The IP numbers are listed as "green" in the IP Address List prior to the reboot, but turn red and must be deleted and re-added in WHM before they will be functional again. Does anyone here know what I need to do to fix this problem permanently? Not only is it a pain to have to re-add the IPs everytime, but it causes website downtime when the server is rebooted.

Btw, my server is assigned a subnet mask of 255.255.254.0, but WHM assumes a default of 255.255.255.0. When I delete and re-add the IPs (after rebooting and they've turned from green to red), I always override the default setting with 255.255.254.0, but is there anyway to edit the WHM configuration so that it defaults to 255.255.254.0?
 

AndyReed

Well-Known Member
PartnerNOC
May 29, 2004
2,221
4
193
Minneapolis, MN
Being hacked is a very typical EV1 problem. It seems that the file where the IPs are saved, get corrupted during rebooting. Now, you need to stop the system from writing to it. SSH to your server and do the following:
chattr +i /etc/nameserverips

Hope this helps!
 
Last edited:

myce

Well-Known Member
Oct 24, 2001
46
0
306
Andy, I tried your suggestion and rebooted, but all IPs (except the master IP) are still turning "red" and must be deleted and re-added. Any other ideas?
 

chirpy

Well-Known Member
Verifed Vendor
Jun 15, 2002
13,465
30
473
Go on, have a guess
Well, the IP addresses are saved in /etc/ips and the virtual network controllers are created by the script /etc/init.d/ipaliases

What do you get with:

chkconfig --list ipaliases

It should be:

ipaliases 0:eek:ff 1:eek:ff 2:eek:n 3:eek:n 4:eek:n 5:eek:n 6:eek:ff

After rebooting, have you tried manually running /etc/init.d/ipaliases to see if that starts up your addon IPs for you? If it does, then I rmember seeing someon else having this problem and a cPanel upgrade seemed to fix it.
 

myce

Well-Known Member
Oct 24, 2001
46
0
306
Jonathan, my results are as follows:

chkconfig --list ipaliases

ipaliases 0:eek:ff 1:eek:ff 2:eek:n 3:eek:n 4:eek:n 5:eek:n 6:eek:ff

/etc/init.d/ipaliases restart

Shutting down eth0:1 SIOCSIFFLAGS: Cannot assign requested address
[FAILED]
UnRouting xx.yy.1.100 SIOCDELRT: No such device
[FAILED]
Shutting down eth0:2 SIOCSIFFLAGS: Cannot assign requested address
[FAILED]
UnRouting xx.yy.1.101 SIOCDELRT: No such device
[FAILED]
Shutting down eth0:3 SIOCSIFFLAGS: Cannot assign requested address
[FAILED]
UnRouting xx.yy.1.102 SIOCDELRT: No such device
[FAILED]
Shutting down eth0:4 SIOCSIFFLAGS: Cannot assign requested address
[FAILED]
UnRouting xx.yy.1.10 SIOCDELRT: No such device
[FAILED]
Shutting down eth0:5 SIOCSIFFLAGS: Cannot assign requested address
[FAILED]
UnRouting xx.yy.1.1 SIOCDELRT: No such device
[FAILED]
Shutting down eth0:6 SIOCSIFFLAGS: Cannot assign requested address
[FAILED]
UnRouting xx.yy.1.137 SIOCDELRT: No such device
[FAILED]
Shutting down eth0:7 SIOCSIFFLAGS: Cannot assign requested address
[FAILED]
UnRouting xx.yy.1.144 SIOCDELRT: No such device
[FAILED]
Bringing up eth0:1 [ OK ]
Routing xx.yy.1.100 [ OK ]
Bringing up eth0:2 [ OK ]
Routing xx.yy.1.101 [ OK ]
Bringing up eth0:3 [ OK ]
Routing xx.yy.1.102 [ OK ]
Bringing up eth0:4 [ OK ]
Routing xx.yy.1.10 [ OK ]
Bringing up eth0:5 [ OK ]
Routing xx.yy.1.1 [ OK ]
Bringing up eth0:6 [ OK ]
Routing xx.yy.1.137 [ OK ]
Bringing up eth0:7 [ OK ]
Routing xx.yy.1.144 [ OK ]
[email protected] [/]#

After running this script, the IPs do turn green again in WHM. FYI, I am running WHM 10.1.0 cPanel 10.2.0-C81 and RedHat Enterprise 3 i686 - WHM X v3.1.0 (CURRENT tree). Any idea what upgrade I might need to apply or why I'm getting the above alert messages?
 
Last edited:

chirpy

Well-Known Member
Verifed Vendor
Jun 15, 2002
13,465
30
473
Go on, have a guess
The errors aren't a problem, that's because you did a restart, but at least the IP's are back up.

I don't know what version would be best, but I'd suggest having a go with EDGE and see if that helps, if it doesn't you're probably best logging a ticket with cPanel.
 

myce

Well-Known Member
Oct 24, 2001
46
0
306
I kind of doubt that going to Edge will solve this since I have been running Automatic Current for the past year. My "guess" is that when EV1 manually installed cPanel after restoring my server that "something" was not configured properly. But, everytime I submit a support ticket to them, they say; "Just delete and re-add the IPs in WHM!" as if that is an acceptable solution!! :mad: Obviously, my virtual network controllers are not being created automatically at system boot! :confused:
 

AndyReed

Well-Known Member
PartnerNOC
May 29, 2004
2,221
4
193
Minneapolis, MN
What is the OS?
Now, when you rebooted the server, did you restart bind, before adding the IPs? Did it work? If not, any error messages: /var/log/messages?
 

myce

Well-Known Member
Oct 24, 2001
46
0
306
Andy, I'm running RedHat Enterprise 3, and I did NOT restart bind before adding the IPs via /etc/init.d/ipaliases start. The only messages in the message log were the ones I noted earlier, although I'm still looking at messages during the reboot for clues.
 

pshepperd

Well-Known Member
Feb 12, 2005
147
0
166
hes running RedHat ES3

Anyhow, your getting this because the shutdown script isn't reading the ips properly from /etc/ips for some reason, are they all in there? and listed properly? I kinda recall it being due to the : in there but I dunno

I think I had this very problem before, but I cant seem to remember what I did, let me dig some more.
 

myce

Well-Known Member
Oct 24, 2001
46
0
306
Yes, all the IPs look good in /etc/ips.
 

pshepperd

Well-Known Member
Feb 12, 2005
147
0
166
Do you have anything in here?

/etc/sysconfig/networking/devices/

Can you aim me, my aim thing is public i think, im going to make it if its not.
 

myce

Well-Known Member
Oct 24, 2001
46
0
306
No, nothing in /etc/sysconfig/networking/devices/.
 

pshepperd

Well-Known Member
Feb 12, 2005
147
0
166
ok, then see if this works for you

create a file this part of the name is for your reference, its pretty much irrelevent as it gets looked at by the networking script at boot, which doesnt care what the name is.

Code:
touch ifcfg-eth0\:1
then edit it with fav. editor

and put this in, making necessary adjustments,
if you have multiple addresses, make a new file, this is how the script works, 1 per file.
Code:
BOOTPROTO=none
DEVICE=eth0:1
NETMASK=255.255.255.255
MTU=1500
BROADCAST=xxx.165.xxx.98
ONPARENT=yes
IPADDR=xxx.165.xxx.98
NETWORK=xxx165.xxx.98
ONBOOT=yes
 

AndyReed

Well-Known Member
PartnerNOC
May 29, 2004
2,221
4
193
Minneapolis, MN
Run these commands at the prompt:
ifconfig eth1 | grep YOUR_MAIN_IP
Then
netstat -rn | grep YOUR_MAIN_IP

Post the results.
 

Kaveyhosting

Well-Known Member
Apr 20, 2005
53
0
156
If all else fails and you think its something with cpanel rebuild cpanel and then rebuild apache.

/scripts/upcp --force

/scripts/easyapache
 

myce

Well-Known Member
Oct 24, 2001
46
0
306
pshepperd, just to be clear, I'm assuming I should use NETMASK=255.255.254.0 since that is my subnet mask. Also, I'm assuming from your example that I'll have one file for each IP address, and I'm to to put the IP address in the BROADCAST, IPADDR, and NETWORK parameters?

------------------------------------------------------------------------------------------------------------

Andy, after running:

ifconfig eth1 | grep YOUR_MAIN_IP

eth1: error fetching interface information: Device not found

netstat -rn | grep YOUR_MAIN_IP

[email protected] [/]#
 

myce

Well-Known Member
Oct 24, 2001
46
0
306
ifconfig eth0 | grep YOUR_MAIN_IP

inet addr:xx.yy.0.72 Bcast:xx.yy.1.255 Mask:255.255.254.0

Also, I have run easyapache, but I don't think I've tried a complete reinstall of cPanel.
 

AndyReed

Well-Known Member
PartnerNOC
May 29, 2004
2,221
4
193
Minneapolis, MN
I want you to run the two command I gave you below right after reboot. I suspect you have either IRQ conflict or hardware problem.