Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am running remote connection on session start using xdg autostart script. But sometimes network interface needs more time to start. So I need to check if network is up.

Is it possible to check if an upstart event was emited (I.e. net-device-up)?

Thank you.

share|improve this question

1 Answer 1

up vote 1 down vote accepted

Short version: No.

Long version: Upstart events themselves are not recorded (unless --verbose or --debug used as init parameter and you grep dmesg). What you can do is check if a job whose start on stanza is net-device-up has been started (or make one for yourself for this purpose only).

Alternatively you can check ifconfig output in your remote connection script for a properly configured eth0 (whatever if you're using).

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.