cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
12892
Views
12
Helpful
8
Replies

switch - how to reboot unresponsive IP camera?

zoumczoumc
Level 1
Level 1

Hello,

I have a Synology NAS that is connected to several IP Cameras through a SG300 switch.

From time to time the IP cameras become "disconnected" at random

When I reboot the switch, the access to cameras is re-established.

Problems:

  1. it requires an external device to reboot the switch
  2. all ports are shutdown while rebooting the switch

Q1

Is there a way to program the SG300 to reboot itself automatically every X hours?

Q2

Is there a way to automate the following process on the SG300 switch itself.

  1. ping a camera every 1 minutes
  2. after three unresponsive ping, shutdown and restart the port to which the camera is connected

Thanks

8 Replies 8

Tom Watts
VIP Alumni
VIP Alumni

Hi Laurent,

There is not any scripting features supported for the switch. There are outside technologies like "wake on LAN" if your network can support it.

You may want to try to globally and per port base disable the EEE features under port management. This may be the cause of the random disconnects.

-Tom
Please rate helpful posts

-Tom Please mark answered for helpful posts http://blogs.cisco.com/smallbusiness/

Hello Tom,

EEE is disabled.

could you explain the WOL part?

Thanks

Laurent

Laurent, I will provide some useful links. WOL is a 3rd party utility.

Here's the wiki link

http://en.wikipedia.org/wiki/Wake-on-LAN

Here's smallnetbuilder's input

http://www.smallnetbuilder.com/lanwan/lanwan-howto/29941-how-to-wake-on-lan-wake-on-wan

Here's a cnet download for free

http://download.cnet.com/Wake-On-LAN/3000-2085_4-10486163.html

-Tom
Please rate helpful posts

-Tom Please mark answered for helpful posts http://blogs.cisco.com/smallbusiness/

w_smith
Level 1
Level 1

Well, I do the following to cycle the PoE on my SG500-28P switch:

snmpset -v2c -c serverswitch POWER-ETHERNET-MIB::pethPsePortAdminEnable.1.61 i 2

sleep 10

snmpset -v2c -c serverswitch POWER-ETHERNET-MIB::pethPsePortAdminEnable.1.61 i 1

And then call that script from a Perl routine that runs in a cron job:

[...]

my $browser = LWP::UserAgent->new;

$browser->timeout(5);

my $url = 'http://:@garagecam.compusmiths.com/jpg/image.jpg';

my $response = $browser->get( $url );

if (!$response->is_success)

{

    printf("No image from GarageCam, power cycling it!\n");

    `/root/reboot-garagecam`;

}

Which power cycles it whenever it fails to supply an image to an HTTP request.

You seem to want to turn the port on and off, which is probably something similar but using the administrative up and down commands, IF-MIB::ifAdminStatus.portnumber

If you unplug the network cable and plug it back in, do you get the same result, o do you really have to reboot the switch?

Dunno how much Linux you can run on that NAS box, or if you have another box that's up all the time, or if you want to plug in something like a Raspberry Pi....

Hi W, Tom

We are nearly there.

When the camera appears disconnected on my Synology, the ping does not work anymore.

You are right,  "unplug the network cable and plug it back in" is working and is the thing I want the SG300 to do for me when it detect that the IP camera traffic is null.

I use a SG300-10, not PoE unfortunately.

If I would know PERL and know how to configure it on Synology, I guess I could program it. But I can't.

This is why I try to have the switch to

  1. SG300-10 detects that the traffic on the IP CAM port is below a threshold or that the device does not respond to a ping
  2. and then perform a  "switchxxxxxx# set interface active gi1" or "switchxxxxxx(config-if)# no shutdown"

I have launched a separate thread https://supportforums.cisco.com/thread/2167753

SG300 - PORT MANAGEMENT - Reactivate Suspended Port - can not activate

to try to solve the same problem in a different way, but the objective is the same

"

Laurent, I guess I am a bit more interested in why it is going to this state. If there is a device connecting to the switchport, it should be able to communicate on demand unless there is something going on with that particular device.

If the switch is the cause of the camera communication it is related to spanning tree, port security, and EEE. If the camera is going in to a sleep state and cannot activate by transmission of interesting packet or the switch pretty much needs to yell "Hey, wake up!" by using a shutdown/no shut command or set interface command it seems the camera's conservation setting may be too low or the NIC on this product is not sensitive enough.

Curious enough, if you set a computer on the LAN to continuously ping the camera, does it ever stop working?

ping cameraip -t

If sending a constant stream of traffic to the camera keeps it working, this is an okay work around. But it doesn't resolve the issue of who is doing what. What is the model of the camera?

-Tom
Please rate helpful posts

-Tom Please mark answered for helpful posts http://blogs.cisco.com/smallbusiness/

I guess I'm less surprised by cameras falling over, Axis at least seems to have outsourced their firmware to Elbonia.

The Axis M1011 camera I have the most trouble with will respond to ping, will open an HTML session, but won't give you a .jpg file.  So I just check it every minute as above and power-cycle the PoE when it doesn't respond.

The 209MFD and M3114 are a little better, but they don't stay up forever either.

dweiss
Level 1
Level 1

New on the market is the iBoot-PoE.  It will ping or monitor traffic from the PoE device and auto reboot.  There is also cloud based management.  You can manage all your locations from a single sign-on. dataprobe.com/iboot-poe

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Switch products supported in this community
Cisco Business Product Family
  • CBS110
  • CBS220
  • CBS250
  • CBS350
Cisco Switching Product Family
  • 110
  • 200
  • 220
  • 250
  • 300
  • 350
  • 350X
  • 550X