Restart Server Post EEPROM.write help

Hello,

I have a project where I may need to change the network settings for my Arduino Ethernet Rev3 w/o PoE from a client. The Arduino loads the IP, DNS, Subnet, and Gateway from the EEPROM. Each of those has 4 bytes in the EEPROM associated with it (0-3, 4-7, 8-11, 12-15). The client sends it an IP, DNS, Subnet, or Gateway to the Arduino and the Arduino then saves that data in the EEPROM. I've wrote all this code already.

/*********************************************************************************
       **                                     EEPROM
       *********************************************************************************/
    case 0x35: // writeEEPROM_IP              
      EEPROM.write(0,command[2]);  // first byte of IP
      EEPROM.write(1,command[3]);  // second byte of IP
      EEPROM.write(2,command[4]);  // third byte of IP
      EEPROM.write(3,command[5]);  // fourth byte of IP  
      Serial.println(Ethernet.localIP());
      client.write('0');
      break;
    case 0x36: // writeEEPROM_DNS           
      EEPROM.write(4,command[2]);  // first byte of DNS
      EEPROM.write(5,command[3]);  // second byte of DNS
      EEPROM.write(6,command[4]);  // third byte of DNS
      EEPROM.write(7,command[5]);  // fourth byte of DNS           
      client.write('0');
      break;
    case 0x37: // writeEEPROM_Gateway              
      EEPROM.write(8,command[2]);  // first byte of gateway
      EEPROM.write(9,command[3]);  // second byte of gateway
      EEPROM.write(10,command[4]);  // third byte of gateway
      EEPROM.write(11,command[5]);  // fourth byte of gateway           
      client.write('0');
      break;
    case 0x38: // writeEEPROM_subnet              
      EEPROM.write(12,command[2]);  // first byte of subnet
      EEPROM.write(13,command[3]);  // second byte of subnet
      EEPROM.write(14,command[4]);  // third byte of subnet
      EEPROM.write(15,command[5]);  // fourth byte of subnet            
      client.write('0');
      break;]

What I need help on is actually updating my server. I've searched around a lot for "restarting" server, "stopping" server, and "update" server on the Arduino.cc forums, but those searches result in fixing problems with servers that are fickle and don't give a constant connection. What I'm looking for is something that will stop my Arduino server, update the settings, and start a new server.

My server is called "server" and I know "server.begin();" starts the server, and I believe "server.stop()" would stop it, but I have not found any documentation to support that from the Arduino Reference page. Ethernet - Arduino Reference

Any suggestions?

Thanks,
Matt

Perhaps it would be easy to just restart the arduino.you could configure the whatchdog timer to cause a reset after updating the eeprom.
I dont know a way to stop de server and restart it again, maybe there is something ...

HugoPT,

I was thinking about that as an option too. I looked here (Two Ways to Reset Arduino in Software (with Pictures) - Instructables)and found an instructable on how to do it two ways. I'm currently using all of the pins on my Arduino Etherenet, so having a pin be the reset indicator may be out of the option. I think I'll have to do that software side. Will I need to write a custom bottloader?

Matt