|
|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 Tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: B T
Length: 3028 (0xbd4)
Types: TextFile
Names: »B«
└─⟦d10a02448⟧ Bits:30000409 8mm tape, Rational 1000, ENVIRONMENT, D_12_7_3
└─⟦fc9b38f02⟧ »DATA«
└─⟦9b46a407a⟧
└─⟦12c68c704⟧
└─⟦this⟧
└─⟦5f3412b64⟧ Bits:30000745 8mm tape, Rational 1000, ENVIRONMENT 12_6_5 TOOLS
└─⟦91c658230⟧ »DATA«
└─⟦458657fb6⟧
└─⟦220843204⟧
└─⟦this⟧
with Daemon;
with Io;
with Log;
with Message;
with Profile;
with Scheduler;
with System_Backup;
with Time_Utilities;
procedure Do_Backup (Variety : System_Backup.Kind := System_Backup.Full;
Starting_At : String := "") is
Delay_For : Duration;
Warning : Duration;
Start_Message : Boolean;
Finish_Message : Boolean;
Got_Snapshot_Info : Boolean := False;
Got_Scheduler_Info : Boolean := False;
Memory_Scheduling : Integer;
Memory_Scheduling_String : constant String := "Memory_Scheduling";
procedure Backup_Finishing (Was_Successful : Boolean) is
begin
if Got_Snapshot_Info then
-- Restore snapshot warning to previous setting
Got_Snapshot_Info := False;
Daemon.Snapshot_Warning_Message (Interval => Warning);
Daemon.Snapshot_Start_Message (Start_Message);
Daemon.Snapshot_Finish_Message (Finish_Message);
end if;
if Got_Scheduler_Info then
-- Restore scheduler settings
Got_Scheduler_Info := False;
Scheduler.Set (Memory_Scheduling_String, Memory_Scheduling);
end if;
end Backup_Finishing;
procedure Backup_Starting (Is_Full : Boolean) is
begin
-- Warn users that backup is starting
if Is_Full then
Message.Send_All ("Starting full system backup");
else
Message.Send_All ("Starting incremental system backup);");
end if;
-- Save current scheduler settings
Memory_Scheduling := Scheduler.Get (Memory_Scheduling_String);
Got_Scheduler_Info := True;
Scheduler.Set (Memory_Scheduling_String, 0); -- turn off scheduling
-- Save current snapshot settings and turn off snapshot warnings.
Daemon.Get_Snapshot_Settings (Warning, Start_Message, Finish_Message);
Got_Snapshot_Info := True;
Daemon.Snapshot_Warning_Message (Interval => 0.0);
Daemon.Snapshot_Start_Message;
end Backup_Starting;
procedure Backup is new System_Backup.Backup_Generic
(Backup_Starting, Backup_Finishing);
begin
if Starting_At'Length > 0 then
begin
Delay_For := Time_Utilities.Duration_Until
(Time_Utilities.Value (Starting_At));
exception
when others =>
Log.Put_Line ("Invalid starting time value given.",
Kind => Profile.Error_Msg);
return;
end;
end if;
-- Do the backup
Backup (Variety => Variety, Wait_Until => Starting_At);
-- Take snapshot to make full backups official; i.e. allow differentials
Daemon.Run ("Snapshot");
exception
when others =>
Io.Put_Line (Io.Current_Error,
"Backup failed with an unhandled exception.");
Backup_Finishing (False);
end Do_Backup;