Tag Info

Hot answers tagged

29

There are a couple of programs that automate this feature, take away the annoyance and potential bugs from doing this yourself, and avoid the stale lock problem by using flock behind the scenes, too (which is a risk if you're just using touch). I've used lockrun and lckdo in the past, but now there's flock(1) (in newish versions of util-linux) which is ...


18

Best way in shell is to use flock(1) ( flock -x -w 5 99 ## Do your stuff here ) 99>/path/to/my.lock


13

Assuming you're just setting the task to "Repeat" in the XP "Scheduled Tasks" system, no further action on your part is needed. Scheduled Tasks won't "Repeat" a task if it's already running. If you want to override that default, you can check the box "If the task is still running, stop it at this time" to cause the task scheduler to kill the last instance ...


8

Actually, flock -n may be used in stead of lckdo*, so you will be using code from kernel developers. Building on womble's example, you would write something like: * * * * * flock -n /some/lockfile command_to_run_every_minute BTW, looking at the code, all of flock, lockrun, and lckdo do the exact same thing, so it's just a matter of which is most readily ...


4

With regards to pico it's unlikely to ever be much cause for concern so it's not the kind of command you would normally nice/renice or ionice. However your command would execute pico niced to +13. Which would mean it would get significantly less time allocated to it. For example, following on from your pico line. Normally pico executed looks like this: ...


4

Two solutions spring to mind: Use xargs -P to control the maximum parallel processes at one time. Create a Makefile and spawn with make -j. They are actually both summarised in this SO thread in more detail. There is a possibility that these may not be applicable to the structure of your scripting.


4

A heavy weight solution to your problem is to use a something like Sun Grid Engine. Sun Grid Engine (SGE). SGE is a distributed resource management software and it allows the resources within the cluster/machine (cpu time,software, licenses etc) to be utilized effectively. Here is a small tutorial on how to use SGE.


4

I'd recommend that you set up your conference rooms as resources. You can then use resource booking to prevent this from happening. Have a look at this article from MSExchange.org for Exchange 2003. Here are articles for Exchange 2007 for making Resource Mailboxes. Part 1 Part 2 Part 3


3

Take a look at JobScheduler - http://jobscheduler.sourceforge.net/ It's free/opensource and very robust. I am currently in the process of implementing this here at work. It's very well documented.


3

I'd set up some kind of queueing service. A quick Google on "ready to use" stuff shows this: http://sqs.sourceforge.net/ Depending on your needs you could simply create a wrapper where users submit jobs, the wrapper writes the job to a socket/file/whatever create a consumer that runs job by job waiting for it to finish the consumer is then called ...


3

Disk i/o scheduler are set per spindle. You can change the scheduling algo for /dev/sda,sdb etc which are real, hardware , devices in your system. Software raid block devices are virtual. Ionice is not related to software raid and it simple gives priority of one process over another when accessing the storage. So yes, you can use it with no matter what type ...


3

this is good links to start : 10 Ways to Automatically & Manually Backup MySQL Database http://www.noupe.com/how-tos/10-ways-to-automatically-manually-backup-mysql-database.html How to setup and verify a backup solution for MySQL in 15 minutes - all using open source software http://www.zmanda.com/quick-mysql-backup.html


3

You might want to read the MySQL documentation on Database Backup Methods. PHPMyAdmin has an "Export" option you can use to backup your database, but there is no way to automate this. Automating a backup of MySQL usually requires creating a CRON Job that calls mysqldump. There are other ways to do it, such as with a file system snapshot, but using ...


3

Automation can be done by creating CRON jobs on your server. The following link has complete example code to backup the database automatically http://atoztechnical.blogspot.com/2010/08/how-to-automate-database-backups.html or First write a script that uses mysqldump command to backup your database and store in specific directory.Now we are going to ...


3

nice priority numbers only matter in relation to other processes. It's up to you to determine the structure you want and how much granularity you need. You can think of it as 3 for very low granularity or 5 groups for better granularity instead of the full range, e.g., High, Medium, Normal, Low, Really Low, and give those an arbitrary number value, say -19, ...


2

Yes, you can configure and run more virtual CPUs than physical cores available. This is an idle Windows Server 2008 (x86, German) KVM guest showing 10 CPUs on a 4-core single-CPU Intel X3210 machine: But you only should do so when you know, what you are doing: For one, this will be accompanied by the overhead of timing / synchronizing more virtual CPUs ...


2

You have it correct in your comment to Abhishek's answer. 0 0 1 3,7,11 * /path/to/file In this case the "/" won't do what you're after.


2

chrt(1) is used not only to change the priority of a process, but also the scheduling policy. The scheduling policy can be four: SCHED_FIFO=first in, first out, real time processes. SCHED_RR=round robin real time processes. SCHED_OTHER=normal time sharing SCHED_BATCH=almost the same as the SCHED_OTHER, but the process is considered always the most ...


2

It's probably fair to ask what type of platforms you're concerned about managing. I'm assuming Linux, but the concept applies to Windows systems as well... You are looking for a job scheduler. It's not an easy thing to get into, but can potentially help scalability and would manage your inter-process dependencies. A good solution to start with is the Open ...


2

ionice is an interface to the IO scheduler subsystem of the Linux kernel, it allows for setting IO priorities on a per process basis. The use-case of that would be something like reducing the priority of the updatedb command that builds the database for the locate command in a way that other IO is running undisturbed as updatedb only gets to do IO when no ...


2

Grant the CAP_SYS_NICE capability.


2

Chris Siebenmann recently came to the same conclusion as you: ionice has no effect on either "software raid" (I presume this means MD) or LVM. http://utcc.utoronto.ca/~cks/space/blog/


2

The way I have done this is to run the task from a batch file that starts once a day shortly after midnight and runs until next midnight. The advantag of this is that because it's a single script you cannot get a second instance running. I suppose a disadvantage might be that you can predict exactly how often the script runs because it would wait a set time ...


2

You can always use lpd -- yeah, old school, but it's really a generalised batch processing control system masquerading as a print server.


1

You could check out some of the batch-systems used for scheduling jobs on clusters, which has the option to monitor resource usage and declare a system to be too loaded to dispatch more workload to it. You could easily also configure them to only run one job at a time, but for that you may be better off with something less complex than a full fledged batch ...


1

From man batch: batch executes commands when system load levels permit; in other words, when the load average drops below 1.5, or the value specified in the invocation of atd. I think this might be what you're looking for. It's part of Debian's at package.


1

After searching through several manuals and many searches on the web, I have to say I don't think it's possible. You could either setup another server to remote in and run a command or... This company sells a solution to schedule and replay tasks: ...


1

In the windows task scheduler there is a checkbox (or options) for what to do if the task is already running when the task starts again. You can set it not to start or run in parallel


1

I was briefly looking into this idea some time ago and came across this page. We ultimately decided against pursuing the idea when the people asking about it decided it wasn't worth the cost.


1

Visix has a digital meeting room sign called MeetingMinder that can support bidirectional communication with Microsoft Exchange (i.e. can show the room schedule on the screen, and the user can book the room from the MeetingMinder).



Only top voted, non community-wiki answers of a minimum length are eligible