Move a print job from one queue to another in Linux

Today, I was looking at my printer queue and realised that Claire had tried to print something from the internet to my work printer. This meant that unless I went to the office – it would not print. A problem.

Because Claire had decided to use my laptop rather than one of the desktops, I was set up for Linux and believed that I could solve this problem someone in a very tekky way.

A quick squint at the internet found Linux Commando’s How to move print jobs from one printer queue to another.

Perfect!

So, to break it down – here’s what you do. Let’s say that you’ve printed to printer B, but you meant to print to printer A, this is what we do.

Step 1

Find the print job number in the queue. The easiest way is at the command prompt

<code>lpq -P printerB</code>

This will show a list of jobs:

printerB is ready and printing
Rank    Owner   Job     File(s)                         Total Size
active  john    180     12 Steps to a Success with Your 182272 bytes

Now we can see that your print job is 180. Great.

Step 2

So I want to move that job to printerA:

<code>sudo lpmove printerB-180 printerA</code>

That’s it. Now if you check the queue for printer A:

<code>lpq -P printerA</code>

You will see the print job printing out. Hurrah!

Prevent WordPress from Hanging when You Log on

I’ve set up a WordPress site for a client and have had no end of troubles trying to get the site to behave – however there seems to be a constant problem of WordPress hanging.

Looking further into it – I discovered that the feeds in the Dashboard were making the browser and site hang. There is likely to be an issue tied into the host / browser / Javascript.

Anyway, if you find that you are having the same problem, follow these directions:

  1. Restart your web browser (if it isn’t already closed)
  2. Beofre visiting your blog, open up the settings and disable javascript. (IE / Firefox / Opera Instructions)
  3. Open up your blog site and log on in the normal way.
  4. On the Dashboard panel, you’ll see that there are now a number of panels that state they require Javascript – great!
    broken_dashboard
  5. On each widget – click on the configure link. Delete the contents of the RSS feed URL and then click on Submit
  6. Once done, you can turn Javascript back on in the broswer settings. You’ll see the widgets appear with errors on them.
    widget_nojs
  7. Now just go to the top of the page and click on Screen Options. Disable the widgets that show an error message and all will be right with the world once again!

It’s a bit of a pain, and I haven’t managed to get to the bottom of the problem as I am never in charge of hosts where the problems lie.

However, this workaround will at least get you going with your blog without any more hassle!

How to edit settings on a Ctrix Metaframe NFuse Server

Something that comes up irregularly with clients: How do I change the settings of the logon screen for Citrix’s web interface?

And the good news is that it’s quite simple.

Open up your webbrowser and goto https://nfuseserver/citrix/metaframe/wiadmin remembering to change nfuseserver with the name of your own server.

Once in, you can configure your farms and servers quite happily.

Oh, and always remember to click on Apply Changes once you’ve saved your new settings.

Now We Can Make Our Own Gigs

I’ve just been reading John Young’s post on his forum about paying for gigs where you live:John Young Message Board – New ways…...

It strikes me as an odd idea where you pledge an amount of money and once there’s enough money pledged, then it’s likely a gig will be arranged.

I suppose this explains it better (but it still leaves me a little confused):

How does it work ?? Well it’s easy some folks will sponsor shows i.e. $500 or £200 etc etc and some will just pay for a ticket or two and some who are curious will just turn up for free… it’s just a way to get heard and a way to make things happen.
Of course if you buy a share of the concert you can sell parts of that share to friends and we can also try and help you move those ‘tickets’ so it doesn’t cost you too much…and of course no money changes hands until the night of the show.
This is starting to get exciting although it will take time to grow…it means there will be an appreciative audience at the gig and that concerts will happen

So there you have it. It will be interesting to see how this comes together, and if it can make a good model for live music and smaller bands and artists.

Bank 2.0 – An Ideal of a Better World

I’ve just read Matt Mullenweg’s thoughts on starting a bank. Not just any bank – but a safe bank.

In the current climate of consumer resentment to their bank, it seems like Matt’s thoughts on starting an internet bank using tried-and-tested internet strategies is a geat idea.

Of course, there is all the fine details. How difficult would it be to get a loan from SafeBank? Or how would one deal with credit cards or “reasonable” fees…

Still, a very interesting premise and one that I might steal for a speech idea! Nice one, Matt!

Deleting files older than a specific date or age

I needed to delete a chunk of cookies today – but I didn’t want to delete them all.

Thankfully there is a handy command that is within Windows versions after XP such as Server 2003 and Vista that will enable to clean up without too many problems.

The forfiles command will allow you to set a specific date for a file so that you don’t delete recent cookies:

<code>forfiles /S /p "C:\Users\John\cookies" /D -150 /c "cmd /c del @path"</code>

If you wanted to be super cool and delete multiple user cookie folders you could do something like this:

<code>for /D %D in (C:\Users\*) DO forfiles /S /p "%D\cookies" /D -150 /c "cmd /c del @path"</code>

This will enumerate all of the user folders in the C:\Users folder and then clean up the cookies folders inside.

If you wanted to – you can change the amount of days from 150 days to any other amount you like by changing /D -150 to any other number of days (or even use a specific date).