diff --git a/NEWS b/NEWS
index 42593d2b41e6e139b2f9911aac06304406814a71..728433b4500cf4e985016f3727cdd528dedce3d1 100644
--- a/NEWS
+++ b/NEWS
@@ -38,6 +38,8 @@ documents those changes that are of interest to users and admins.
     than one partition uses a node or there is more than one socket per node.
  -- In output for "scontrol show job" change "StartTime" header to "EligibleTime"
     for pending jobs to accurately describe what is reported.
+ -- Add more slurmdbd.conf paramters: ArchiveScript, ArchiveAge, JobPurge, and
+    StepPurge (not fully implemented yet).
 
 * Changes in SLURM 1.3.3
 ========================
diff --git a/doc/man/man5/slurmdbd.conf.5 b/doc/man/man5/slurmdbd.conf.5
index 0b55090de0d388f068c1a228edf7688c2c1b2af0..e1435514f311c7814bb8445855c702045fefb6ac 100644
--- a/doc/man/man5/slurmdbd.conf.5
+++ b/doc/man/man5/slurmdbd.conf.5
@@ -1,4 +1,4 @@
-.TH "slurmdbd.conf" "5" "February 2008" "slurmdbd.conf 1.3" "Slurm configuration file"
+.TH "slurmdbd.conf" "5" "June 2008" "slurmdbd.conf 1.3" "Slurm configuration file"
 .SH "NAME"
 slurmdbd.conf \- Slurm Database Daemon (SlurmDBD) configuration file 
 
@@ -21,6 +21,32 @@ This file should be protected from unauthorized access since it
 contains a database password.
 The overall configuration parameters available include:
 
+.TP
+\fBAllowView\fR
+This controls who can view accounting records. 
+A value of "user" prevents normal users from viewing accounting records
+that are not generated directly by them (preventing them from viewing 
+any other users jobs).
+A value of "account" prevents normal users from viewing accounting 
+records that are not generated by users in the same account.
+A value of "none" lets any user view accounting records generated by 
+any other user.
+The default value is "none".
+
+.TP
+\fBArchiveAge\fR
+Move data over this age out of the database to an archive.
+The time is a numeric value and is a number of days.
+If zero, then never archive the data.
+The default value is zero.
+
+.TP
+\fBArchiveScript\fR
+This script is executed periodically in order to transfer accounting
+records out of the database into an archive. The script is executed 
+with a single argument, the value of \fBArchiveTime\fR as described
+below.
+
 .TP
 \fBAuthInfo\fR
 Additional information to be used for authentication of communications 
@@ -84,6 +110,14 @@ Values from 0 to 7 are legal, with `0' being "quiet" operation and
 `7' being insanely verbose.
 The default value is 3.
 
+.TP
+\fBJobPurge\fR
+Individual job records over this age are purged from the database.
+Aggregated information will be preserved indefinitely.
+The time is a numeric value and is a number of days.
+If zero, then job records are never purged.
+The default value is 360 days.
+
 .TP
 \fBLogFile\fR
 Fully qualified pathname of a file into which the Slurm Database Daemon's 
@@ -116,6 +150,14 @@ and have the same user ID as the hosts on which \fBslurmctld\fR execute.
 For security purposes, a user other than "root" is recommended.
 The default value is "root". 
 
+.TP
+\fBStepPurge\fR
+Individual job step records over this age are purged from the database.
+Aggregated information will be preserved indefinitely.
+The time is a numeric value and is a number of days.
+If zero, then job step records are never purged.
+The default value is 30 days.
+
 .TP
 \fBStorageHost\fR
 Define the name of the host the database is running where we are going
@@ -168,6 +210,10 @@ with to store the job accounting data.
 .br
 #
 .br
+ArchiveAge=365   # keep 1 year of data online
+.br
+ArchiveScript=/usr/sbin/slurm.dbd.archive
+.br
 AuthInfo=/var/run/munge/munge.socket.2
 .br
 AuthType=auth/munge
@@ -176,6 +222,10 @@ DbdHost=db_host
 .br
 DebugLevel=4
 .br
+JobPurge=90
+.br
+StepPurge=30
+.br
 LogFile=/var/log/slurmdbd.log
 .br
 PidFile=/var/tmp/jette/slurmdbd.pid
diff --git a/src/slurmdbd/read_config.c b/src/slurmdbd/read_config.c
index 73bf525190b38374d8e854aee72e8c7512a86747..214d14dc2272558a7d4ecf06472da70229f3aa59 100644
--- a/src/slurmdbd/read_config.c
+++ b/src/slurmdbd/read_config.c
@@ -75,15 +75,19 @@ extern void free_slurmdbd_conf(void)
 static void _clear_slurmdbd_conf(void)
 {
 	if (slurmdbd_conf) {
+		slurmdbd_conf->archive_age = 0;
+		xfree(slurmdbd_conf->archive_script);
 		xfree(slurmdbd_conf->auth_info);
 		xfree(slurmdbd_conf->auth_type);
 		xfree(slurmdbd_conf->dbd_addr);
 		xfree(slurmdbd_conf->dbd_host);
 		slurmdbd_conf->dbd_port = 0;
+		slurmdbd_conf->job_purge = 0;
 		xfree(slurmdbd_conf->log_file);
 		xfree(slurmdbd_conf->pid_file);
 		xfree(slurmdbd_conf->plugindir);
 		xfree(slurmdbd_conf->slurm_user_name);
+		slurmdbd_conf->step_purge = 0;
 		xfree(slurmdbd_conf->storage_host);
 		xfree(slurmdbd_conf->storage_loc);
 		xfree(slurmdbd_conf->storage_pass);
@@ -102,17 +106,21 @@ static void _clear_slurmdbd_conf(void)
 extern int read_slurmdbd_conf(void)
 {
 	s_p_options_t options[] = {
+		{"ArchiveAge", S_P_UINT16},
+		{"ArchiveScript", S_P_STRING},
 		{"AuthInfo", S_P_STRING},
 		{"AuthType", S_P_STRING},
 		{"DbdAddr", S_P_STRING},
 		{"DbdHost", S_P_STRING},
 		{"DbdPort", S_P_UINT16},
 		{"DebugLevel", S_P_UINT16},
+		{"JobPurge", S_P_UINT16},
 		{"LogFile", S_P_STRING},
 		{"MessageTimeout", S_P_UINT16},
 		{"PidFile", S_P_STRING},
 		{"PluginDir", S_P_STRING},
 		{"SlurmUser", S_P_STRING},
+		{"StepPurge", S_P_UINT16},
 		{"StorageHost", S_P_STRING},
 		{"StorageLoc", S_P_STRING},
 		{"StoragePass", S_P_STRING},
@@ -144,12 +152,16 @@ extern int read_slurmdbd_conf(void)
 		 	     conf_path);
 		}
 
+		s_p_get_uint16(&slurmdbd_conf->archive_age, "ArchiveAge", tbl);
+		s_p_get_string(&slurmdbd_conf->archive_script, "ArchiveScript", tbl);
 		s_p_get_string(&slurmdbd_conf->auth_info, "AuthInfo", tbl);
 		s_p_get_string(&slurmdbd_conf->auth_type, "AuthType", tbl);
 		s_p_get_string(&slurmdbd_conf->dbd_host, "DbdHost", tbl);
 		s_p_get_string(&slurmdbd_conf->dbd_addr, "DbdAddr", tbl);
 		s_p_get_uint16(&slurmdbd_conf->dbd_port, "DbdPort", tbl);
 		s_p_get_uint16(&slurmdbd_conf->debug_level, "DebugLevel", tbl);
+		if (!s_p_get_uint16(&slurmdbd_conf->job_purge, "JobPurge", tbl))
+			slurmdbd_conf->job_purge = DEFAULT_SLURMDBD_JOB_PURGE;
 		s_p_get_string(&slurmdbd_conf->log_file, "LogFile", tbl);
 		if (!s_p_get_uint16(&slurmdbd_conf->msg_timeout,
 				    "MessageTimeout", tbl))
@@ -162,6 +174,8 @@ extern int read_slurmdbd_conf(void)
 		s_p_get_string(&slurmdbd_conf->plugindir, "PluginDir", tbl);
 		s_p_get_string(&slurmdbd_conf->slurm_user_name, "SlurmUser",
 			       tbl);
+		if (!s_p_get_uint16(&slurmdbd_conf->step_purge, "StepPurge", tbl))
+			slurmdbd_conf->step_purge = DEFAULT_SLURMDBD_STEP_PURGE;
 		s_p_get_string(&slurmdbd_conf->storage_host,
 				"StorageHost", tbl);
 		s_p_get_string(&slurmdbd_conf->storage_loc,
@@ -215,18 +229,22 @@ extern int read_slurmdbd_conf(void)
 /* Log the current configuration using verbose() */
 extern void log_config(void)
 {
+	debug2("ArchiveAge        = %u days", slurmdbd_conf->archive_age);
+	debug2("ArchiveScript     = %s", slurmdbd_conf->archive_script);
 	debug2("AuthInfo          = %s", slurmdbd_conf->auth_info);
 	debug2("AuthType          = %s", slurmdbd_conf->auth_type);
 	debug2("DbdAddr           = %s", slurmdbd_conf->dbd_addr);
 	debug2("DbdHost           = %s", slurmdbd_conf->dbd_host);
 	debug2("DbdPort           = %u", slurmdbd_conf->dbd_port);
 	debug2("DebugLevel        = %u", slurmdbd_conf->debug_level);
+	debug2("JobPurge          = %u days", slurmdbd_conf->job_purge);
 	debug2("LogFile           = %s", slurmdbd_conf->log_file);
 	debug2("MessageTimeout    = %u", slurmdbd_conf->msg_timeout);
 	debug2("PidFile           = %s", slurmdbd_conf->pid_file);
 	debug2("PluginDir         = %s", slurmdbd_conf->plugindir);
 	debug2("SlurmUser         = %s(%u)", 
-		slurmdbd_conf->slurm_user_name, slurmdbd_conf->slurm_user_id); 
+		slurmdbd_conf->slurm_user_name, slurmdbd_conf->slurm_user_id);
+	debug2("StepAge           = %u days", slurmdbd_conf->job_purge); 
 	debug2("StorageHost       = %s", slurmdbd_conf->storage_host);
 	debug2("StorageLoc        = %s", slurmdbd_conf->storage_loc);
 	debug2("StoragePass       = %s", slurmdbd_conf->storage_pass);
diff --git a/src/slurmdbd/read_config.h b/src/slurmdbd/read_config.h
index 79d09c5141db385e4e57ea806ee13f6c439cef75..8c5895252593af2bafb64622a09fdfe366db54fb 100644
--- a/src/slurmdbd/read_config.h
+++ b/src/slurmdbd/read_config.h
@@ -55,25 +55,31 @@
 #include <time.h>
 
 #define DEFAULT_SLURMDBD_AUTHTYPE	"auth/none"
+#define DEFAULT_SLURMDBD_JOB_PURGE	360
 #define DEFAULT_SLURMDBD_PIDFILE	"/var/run/slurmdbd.pid"
+#define DEFAULT_SLURMDBD_STEP_PURGE	30
 
 /* SlurmDBD configuration parameters */
 typedef struct slurm_dbd_conf {
 	time_t		last_update;	/* time slurmdbd.conf read	*/
+	uint16_t	archive_age;	/* archive data this age	*/
+	char *		archive_script;	/* script to archive old data	*/
 	char *		auth_info;	/* authentication info		*/
 	char *		auth_type;	/* authentication mechanism	*/
 	char *		dbd_addr;	/* network address of Slurm DBD	*/
 	char *		dbd_host;	/* hostname of Slurm DBD	*/
 	uint16_t	dbd_port;	/* port number for RPCs to DBD	*/
 	uint16_t	debug_level;	/* Debug level, default=3	*/
+	uint16_t	job_purge;	/* purge time for job info	*/ 
 	char *		log_file;	/* Log file			*/
-	uint16_t        msg_timeout;    /* message timeout */   
+	uint16_t        msg_timeout;    /* message timeout		*/   
 	char *		pid_file;	/* where to store current PID	*/
 	char *		plugindir;	/* dir to look for plugins	*/
 	uint32_t	slurm_user_id;	/* uid of slurm_user_name	*/
 	char *		slurm_user_name;/* user that slurmcdtld runs as	*/
+	uint16_t	step_purge;	/* purge time for step info	*/
 	char *		storage_host;	/* host where DB is running	*/
-	char *		storage_loc;	/* database name */
+	char *		storage_loc;	/* database name		*/
 	char *		storage_pass;   /* password for DB write	*/
 	uint16_t	storage_port;	/* port DB is listening to	*/
 	char *		storage_type;	/* DB to be used for storage	*/