Periodically Restart Chromium via Cron

Questions about applications and software
Forum rules
Before you post please read how to get help
Post Reply
klawncare1239
Level 1
Level 1
Posts: 8
Joined: Wed Nov 11, 2015 12:45 pm

Periodically Restart Chromium via Cron

Post by klawncare1239 » Sat Jun 16, 2018 8:08 am

Hey, folks. Been searching for a good solution to this for a couple days now. Haven't quite nailed it.

My issue is, there is not a good tab session manager for Chrome which appears to ACTUALLY save my session periodically so that, should I have a crash or unexpected failure, I would never lose my tabs.

"Session Manager" has worked well for me in the past, but, only saves a session when I manually save one or when I close Chromium. Since I'm not going to remember to manually save a session periodically, I am looking for another solution.

I tried "Fresh Start" extension, which claims to have this functionality, but it doesn't work (and numerous other reviews suggest it does not either), and hasn't been updated since 2015 or 16. So, I don't think this is an option.

My last resort is that I was going to setup a cronjob to restart Chromium every half hour or so, effectively forcing "Session Manager" to autosave my session each time Chromium restarts. Of course, if someone has a better solution I'm certainly open to it, as this isn't ideal.

But, if not, then I'm looking for someone to help me create the cronjob syntax to make it work properly. I've tried formulating it in various ways, but it doesn't seem to work. I have tested and confirmed that cron will run cronjobs, so there is no problem there. The problem is not with my "timing" settings, since, at this point I've been setting it to run every minute with all "*" so that I could see it in action and quickly make sure it was working. The problem is definitely with my command.

Suggestions as to how I could formulate the command to make this work most efficiently (or if there is another automated way to save sessions periodically)?

My current command is:

* * * * * killall chromium-browser >>/var/log/chromium-restart.log 2>&1

However, I have tried numerous other variations including "restart", using the full path to Chromium, etc. Just can't seem to get the right combination to make it work.

klawncare1239
Level 1
Level 1
Posts: 8
Joined: Wed Nov 11, 2015 12:45 pm

Re: Periodically Restart Chromium via Cron

Post by klawncare1239 » Sun Jun 17, 2018 12:00 am

Someone has to know how to do this. I'm certain it's not that difficult. Just, for some reason, can't get the command right.

Post Reply

Return to “Software & Applications”