[SOLVED] Need Network status and restart help on SuSE system with KDE tools
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Need Network status and restart help on SuSE system with KDE tools
Hi all,
I have very limited experience with Linux. I have a device running an application that needs to programatically query the networking status and if an issue is found, restart it. I can't seem to run /etc/init.d/networking even using sudo. I can see the init process is running if I issue the "top" command, but I don't see "Networking" in the list.
In general, I know how to build the application and make minor changes and reinstall into the device. Outside of that, Linux is pretty much a black box to me ;-)
Thanks for any guidance you can give me.
drb
Last edited by drb; 05-23-2011 at 12:08 PM.
Reason: typo
Hi all,
I have very limited experience with Linux. I have a device running an application that needs to programatically query the networking status and if an issue is found, restart it. I can't seem to run /etc/init.d/networking even using sudo. I can see the init process is running if I issue the "top" command, but I don't see "Networking" in the list.
In general, I know how to build the application and make minor changes and reinstall into the device. Outside of that, Linux is pretty much a black box to me ;-)
Thanks for any guidance you can give me.
drb
Try an "ls /etc/init.d/net*". I think you'll see that it's "/etc/init.d/network", not "networking", so give that a shot. Your subject line indicates that you're using SuSE, but you don't say what version, so it's hard to be more specific.
Thanks for response. I think you nailed it. As for version, when I issue uname command, it indicates 2.4.0 but not sure if that is version you are after.
So, if I want to issue the restart programically, I'm thinking:
I think you need to clarify, because "networking" and Network Manager (/etc/init.d/network) are two completely different things. You don't necessarily need the second to have the first.
Again, my lack of experience with Linux is showing ;-) So, by way of background, the situation is one where the device is losing its network connectivity at some time (probably due to some network scanning tool) and since we have not been able to figure out a root cause, our approach is to simply watch from within the device (is there a prefered way to do this?) to see if we think our network has lost connection with the outside world. If so, then we restart the network using the "/etc/init.d/network restart" command. Perhaps I'm way off base on either or both of these parts of the approach. I'm all ears if there is a better way to do it.
In this case, Network Manager may be the cause, not the solution. I've seen a lot of issues reported with it. I never use it, and I never have network problems. It might be worth your while to try turning that off, and see what happens.
To disable it, launch Yast, go to Network Devices -> Network Settings -> Global Options, and change the checkbox to "Traditional Method with ifup."
I'd like to try disabling the Network Manager as you suggest. However, since the final product is a stand alone unit and does not have an external interface I can use, I'd need to do it by adjusting ini files or the equilavent during startup (has to be automatic, no user interaction possible). If you have insight as to how to do this, please let me know.
Just FYI, I do need to use things like DHCP, HTTP, FTP, and PING still, so if those would be lost, then I'll need to figure out how to do this and have them still available.
Thanks for your continued interest in my issue.
drb
Last edited by drb; 05-23-2011 at 03:18 PM.
Reason: added content/context
I'd like to try disabling the Network Manager as you suggest. However, since the final product is a stand alone unit and does not have an external interface I can use, I'd need to do it by adjusting ini files or the equilavent during startup (has to be automatic, no user interaction possible). If you have insight as to how to do this, please let me know.
I don't understand what you mean by this. Please elaborate.
Quote:
Originally Posted by drb
Just FYI, I do need to use things like DHCP, HTTP, FTP, and PING still, so if those would be lost, then I'll need to figure out how to do this and have them still available.
These functions are all independent of Network Manager.
Elaboration: OK, so I've actually got two Linux systems. The build system, which is actually the one I originally described and that I can try things on via command line, and the target device which is standalone and has no user interface (save a few buttons which are monitored by apps). The target system is still Linux, but I don't even know how to know what version it is. I suppose I could Telnet into it and see what it is and probably should. Anyway, the target system is the one that eventually stops working and needs to be preferably automatically noticed and only affected systems restarted (hopefully only Network systems?). We can tell when it fails because it stops responding to pings but all else still works. We are fairly confident that some security network scan is causing the issue (for unknown reason). This effects so few units a very specific sites that we are inclined to the workaround I've described rather than a full blown investigation ;-)
Like I said, I don't know much about Linux in either case. I know just enough to build the target code image and upload it to the target system. After that, I can make minor changes to the existing apps (one of which is in a loop I can use to monitor Network issues and cause Network restart).
I had this plopped in my lap and really have no background to assist further.
Thanks,
drb
Last edited by drb; 05-23-2011 at 05:33 PM.
Reason: omitted word
Okay, I guess I know what you mean about the interface now.
I'd say that if you're going to fix anything on the target box, you're going to have to start getting familiar with the command line. The good news is, the Yast tool I mentioned earlier has an ncurses interface, so it'll give you a graphic-like interface within a normal command shell. The directions I gave for disabling Network Manager work the same whether you're doing it from a command line or a desktop environment.
You're going to need root access to the box to do it, or else get someone else who has root to do it for you.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.