Re: permutations algorithm



If I understand you correctly, I think you may be trying to be too clever.

I guess that each of these members represents a server to be restored and
will have associated with it the number of slots it requires in the tape
library. So the objective is to see which servers you can fit into your 36
slot library, and which you'll need to leave for later.

Wouldn't it be much simpler to just sort by the number of tape slots
required and then work from the smallest one up? That would be trivial to
code and would probably produce just as good results. It might not give you
the "best fit" but you don't really need to care if you've got some empty
tape slots, providing that your servers get restored efficiently.

That method won't always give the best results, but it should be OK unless
you've got a lot more servers and tapes than you can fit, (so you're doing
at least three sets of restores).

--
Simon Green
EDS

-----Original Message-----
From: IBM AIX Discussion List [mailto:aix-l@xxxxxxxxxxxxx] On Behalf Of
Taylor, David
Sent: 09 October 2006 22:37
To: aix-l@xxxxxxxxxxxxx
Subject: permutations algorithm



Admins:



I am looking for an algorithm to determine all the possible list of
permutations for a list of arguments that can range anywhere from 1 to 6.



For example, if the list is A B C, I want the algorithm to spit out:

A

B

C

AB

AC

BC

ABC



The maximum number of members would be six the minimum would be one.



Pseudo-code is just fine.



In case anyone is curious, the purpose of the algorithm will be used in a
script for determining servers to restore in a DR/BCP environment. I have a
very limited capacity library (36 slot - 3583) and I want to be able to
determine, given a list of servers to restore, which combination would give
me the most number of servers I could restore at one time and still have all
of the required tapes still fit in the library.



Backupsets, collocation, hot-site SAN, et.... Have all been suggested and
some form of improvement will be implemented the next year or two but, in
the meatime I have to do the best I can with what I have.



Relevant Pages

  • Re: How to make an AD clone without replication
    ... Shadow Copy Components/System State for all servers. ... After the restore things look ok but I'm having problems. ... I used to just take my most recent backup tapes, ... environment to a test environment. ...
    (microsoft.public.windows.server.active_directory)
  • permutations algorithm
    ... permutations for a list of arguments that can range anywhere from 1 to ... For example, if the list is A B C, I want the algorithm to spit out: ... a script for determining servers to restore in a DR/BCP environment. ...
    (AIX-L)
  • Re: backup of disk image to tape but i need some flexiblity when restoring !
    ... >I have a few linux servers that i want to be able to restore in no time, ... >i was thinking of dumping the entire disk contents to tape using dd. ...
    (comp.os.linux.misc)
  • Re: AD Disaster Recovery Test in Lab Environment
    ... restored DC on the same routed network as the live AD is asking for trouble. ... Alternatively, if your restore hardware is identical to the live stuff, you ... > They are two different subnets, but the two subnets can talk to each other ... > so far has been that if I restore one of the servers, ...
    (microsoft.public.win2000.active_directory)
  • "Time" Reseting the date on DR Domain controllers for a point in t
    ... So for this I must reset the date on the servers to be Wednesday for ... have to process the restore the day believing the day is Wednesday to finish ... I have recently consolidated our DR W2k domain into our production W2k ... properly I must reset the date on the DC's. ...
    (microsoft.public.win2000.active_directory)