public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Move global configuration files to client dir
@ 2009-11-11 11:24 Lucas Meneghel Rodrigues
  2009-11-11 15:32 ` [Autotest] " John Admanski
  0 siblings, 1 reply; 10+ messages in thread
From: Lucas Meneghel Rodrigues @ 2009-11-11 11:24 UTC (permalink / raw)
  To: autotest; +Cc: kvm, Lucas Meneghel Rodrigues

So this way the client can also benefit from settings
defined on the configuration files.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
---
 client/common_lib/global_config.py |    4 +-
 client/global_config.ini           |   90 ++++++++++++++++++++++++++++++++++++
 client/shadow_config.ini           |    3 +
 global_config.ini                  |   90 ------------------------------------
 shadow_config.ini                  |    3 -
 5 files changed, 95 insertions(+), 95 deletions(-)
 create mode 100644 client/global_config.ini
 create mode 100644 client/shadow_config.ini
 delete mode 100644 global_config.ini
 delete mode 100644 shadow_config.ini

diff --git a/client/common_lib/global_config.py b/client/common_lib/global_config.py
index 2bbeca0..1ced7db 100644
--- a/client/common_lib/global_config.py
+++ b/client/common_lib/global_config.py
@@ -10,9 +10,9 @@ from autotest_lib.client.common_lib import error
 
 dirname = os.path.dirname(sys.modules[__name__].__file__)
 DEFAULT_CONFIG_FILE = os.path.abspath(os.path.join(dirname,
-                                                "../../global_config.ini"))
+                                                "../global_config.ini"))
 DEFAULT_SHADOW_FILE = os.path.abspath(os.path.join(dirname,
-                                                "../../shadow_config.ini"))
+                                                "../shadow_config.ini"))
 
 
 class ConfigError(error.AutotestError):
diff --git a/client/global_config.ini b/client/global_config.ini
new file mode 100644
index 0000000..149c4c4
--- /dev/null
+++ b/client/global_config.ini
@@ -0,0 +1,90 @@
+[TKO]
+host: localhost
+database: tko
+db_type: mysql
+user: autotest
+password: please_set_this_password
+readonly_host: localhost
+readonly_user: nobody
+readonly_password:
+query_timeout: 3600
+min_retry_delay: 20
+max_retry_delay: 60
+graph_cache_creation_timeout_minutes: 10
+
+[AUTOTEST_WEB]
+host: localhost
+database: autotest_web
+db_type: mysql
+user: autotest
+password: please_set_this_password
+job_timeout_default: 72
+job_max_runtime_hrs_default: 72
+parse_failed_repair_default: 0
+# Only set this if your server is not 'http://[SERVER] hostname/afe/'
+#base_url: http://your_autotest_server/afe/
+
+[AUTOSERV]
+# Autotest potential install paths
+client_autodir_paths: /usr/local/autotest,/home/autotest
+
+[SERVER]
+hostname: autotest
+# Turn on RPC Logging
+rpc_logging: False
+# Note the user that is running the webserver has to be able to write
+# to the below directory/file otherwise the frontend will not work with logging
+rpc_log_path: /usr/local/autotest/logs/rpcserver.log
+# Number of old logs to keep around
+rpc_num_old_logs: 5
+rpc_max_log_size_mb: 20
+# If for some reason you don't want to rely on the Mail Transport Agent
+# installed on this machine, you can provide an SMTP server directly here.
+# If none provided, defaults to 'localhost', which tries to use the MTA
+# configured on the machine to send the messages.
+smtp_server:
+smtp_port:
+smtp_user:
+smtp_password:
+
+[CLIENT]
+# Drop test client caches between every test execution
+drop_caches: True
+# Drop test client caches between every test iteration execution
+drop_caches_between_iterations: True
+
+[SCHEDULER]
+die_on_orphans: False
+enable_scheduler: True
+notify_email:
+notify_email_from:
+notify_email_statuses: Completed,Failed,Aborted
+max_processes_per_drone: 1000
+max_jobs_started_per_cycle: 100
+max_parse_processes: 5
+max_transfer_processes: 50
+tick_pause_sec: 5
+clean_interval_minutes: 60
+drones: localhost
+drone_installation_directory: /usr/local/autotest
+results_host: localhost
+results_host_installation_directory:
+secs_to_wait_for_atomic_group_hosts: 600
+pidfile_timeout_mins: 300
+max_pidfile_refreshes: 2000
+
+[HOSTS]
+wait_up_processes:
+default_protection: NO_PROTECTION
+
+[AUTOSERV]
+# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
+# another one based on the python SSH library paramiko (paramiko).
+# You can change the default 'raw_ssh' to 'paramiko' if you want to.
+ssh_engine: raw_ssh
+# Autotest server operators *really should* set this to True, specially if
+# using ssh_engine 'paramiko'.
+require_atfork_module: False
+
+[PACKAGES]
+serve_packages_from_autoserv: True
diff --git a/client/shadow_config.ini b/client/shadow_config.ini
new file mode 100644
index 0000000..12b00a5
--- /dev/null
+++ b/client/shadow_config.ini
@@ -0,0 +1,3 @@
+#[TKO]
+#user: autotest
+#password: mypassword
diff --git a/global_config.ini b/global_config.ini
deleted file mode 100644
index 149c4c4..0000000
--- a/global_config.ini
+++ /dev/null
@@ -1,90 +0,0 @@
-[TKO]
-host: localhost
-database: tko
-db_type: mysql
-user: autotest
-password: please_set_this_password
-readonly_host: localhost
-readonly_user: nobody
-readonly_password:
-query_timeout: 3600
-min_retry_delay: 20
-max_retry_delay: 60
-graph_cache_creation_timeout_minutes: 10
-
-[AUTOTEST_WEB]
-host: localhost
-database: autotest_web
-db_type: mysql
-user: autotest
-password: please_set_this_password
-job_timeout_default: 72
-job_max_runtime_hrs_default: 72
-parse_failed_repair_default: 0
-# Only set this if your server is not 'http://[SERVER] hostname/afe/'
-#base_url: http://your_autotest_server/afe/
-
-[AUTOSERV]
-# Autotest potential install paths
-client_autodir_paths: /usr/local/autotest,/home/autotest
-
-[SERVER]
-hostname: autotest
-# Turn on RPC Logging
-rpc_logging: False
-# Note the user that is running the webserver has to be able to write
-# to the below directory/file otherwise the frontend will not work with logging
-rpc_log_path: /usr/local/autotest/logs/rpcserver.log
-# Number of old logs to keep around
-rpc_num_old_logs: 5
-rpc_max_log_size_mb: 20
-# If for some reason you don't want to rely on the Mail Transport Agent
-# installed on this machine, you can provide an SMTP server directly here.
-# If none provided, defaults to 'localhost', which tries to use the MTA
-# configured on the machine to send the messages.
-smtp_server:
-smtp_port:
-smtp_user:
-smtp_password:
-
-[CLIENT]
-# Drop test client caches between every test execution
-drop_caches: True
-# Drop test client caches between every test iteration execution
-drop_caches_between_iterations: True
-
-[SCHEDULER]
-die_on_orphans: False
-enable_scheduler: True
-notify_email:
-notify_email_from:
-notify_email_statuses: Completed,Failed,Aborted
-max_processes_per_drone: 1000
-max_jobs_started_per_cycle: 100
-max_parse_processes: 5
-max_transfer_processes: 50
-tick_pause_sec: 5
-clean_interval_minutes: 60
-drones: localhost
-drone_installation_directory: /usr/local/autotest
-results_host: localhost
-results_host_installation_directory:
-secs_to_wait_for_atomic_group_hosts: 600
-pidfile_timeout_mins: 300
-max_pidfile_refreshes: 2000
-
-[HOSTS]
-wait_up_processes:
-default_protection: NO_PROTECTION
-
-[AUTOSERV]
-# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
-# another one based on the python SSH library paramiko (paramiko).
-# You can change the default 'raw_ssh' to 'paramiko' if you want to.
-ssh_engine: raw_ssh
-# Autotest server operators *really should* set this to True, specially if
-# using ssh_engine 'paramiko'.
-require_atfork_module: False
-
-[PACKAGES]
-serve_packages_from_autoserv: True
diff --git a/shadow_config.ini b/shadow_config.ini
deleted file mode 100644
index 12b00a5..0000000
--- a/shadow_config.ini
+++ /dev/null
@@ -1,3 +0,0 @@
-#[TKO]
-#user: autotest
-#password: mypassword
-- 
1.6.2.5


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 11:24 [PATCH] Move global configuration files to client dir Lucas Meneghel Rodrigues
@ 2009-11-11 15:32 ` John Admanski
  2009-11-11 17:16   ` Lucas Meneghel Rodrigues
  0 siblings, 1 reply; 10+ messages in thread
From: John Admanski @ 2009-11-11 15:32 UTC (permalink / raw)
  To: Lucas Meneghel Rodrigues; +Cc: autotest, kvm

I don't think this is sufficient. It works in the simple cases, but
what about when you're using packaging to install the clients and not
rsync? I guess that still technically works...assuming that you
rebuild the client package whenever you need to change the .ini.

While not strictly wrong, this solution strikes me as really
inelegant. Its interaction with client installs is messy, and it
changes what is a very user-facing component (the ini file) in a very
dramatic way. At the very least we'd need to update all the
documentation on the website that refers to the global config.

-- John

On Wed, Nov 11, 2009 at 3:24 AM, Lucas Meneghel Rodrigues
<lmr@redhat.com> wrote:
> So this way the client can also benefit from settings
> defined on the configuration files.
>
> Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
> ---
>  client/common_lib/global_config.py |    4 +-
>  client/global_config.ini           |   90 ++++++++++++++++++++++++++++++++++++
>  client/shadow_config.ini           |    3 +
>  global_config.ini                  |   90 ------------------------------------
>  shadow_config.ini                  |    3 -
>  5 files changed, 95 insertions(+), 95 deletions(-)
>  create mode 100644 client/global_config.ini
>  create mode 100644 client/shadow_config.ini
>  delete mode 100644 global_config.ini
>  delete mode 100644 shadow_config.ini
>
> diff --git a/client/common_lib/global_config.py b/client/common_lib/global_config.py
> index 2bbeca0..1ced7db 100644
> --- a/client/common_lib/global_config.py
> +++ b/client/common_lib/global_config.py
> @@ -10,9 +10,9 @@ from autotest_lib.client.common_lib import error
>
>  dirname = os.path.dirname(sys.modules[__name__].__file__)
>  DEFAULT_CONFIG_FILE = os.path.abspath(os.path.join(dirname,
> -                                                "../../global_config.ini"))
> +                                                "../global_config.ini"))
>  DEFAULT_SHADOW_FILE = os.path.abspath(os.path.join(dirname,
> -                                                "../../shadow_config.ini"))
> +                                                "../shadow_config.ini"))
>
>
>  class ConfigError(error.AutotestError):
> diff --git a/client/global_config.ini b/client/global_config.ini
> new file mode 100644
> index 0000000..149c4c4
> --- /dev/null
> +++ b/client/global_config.ini
> @@ -0,0 +1,90 @@
> +[TKO]
> +host: localhost
> +database: tko
> +db_type: mysql
> +user: autotest
> +password: please_set_this_password
> +readonly_host: localhost
> +readonly_user: nobody
> +readonly_password:
> +query_timeout: 3600
> +min_retry_delay: 20
> +max_retry_delay: 60
> +graph_cache_creation_timeout_minutes: 10
> +
> +[AUTOTEST_WEB]
> +host: localhost
> +database: autotest_web
> +db_type: mysql
> +user: autotest
> +password: please_set_this_password
> +job_timeout_default: 72
> +job_max_runtime_hrs_default: 72
> +parse_failed_repair_default: 0
> +# Only set this if your server is not 'http://[SERVER] hostname/afe/'
> +#base_url: http://your_autotest_server/afe/
> +
> +[AUTOSERV]
> +# Autotest potential install paths
> +client_autodir_paths: /usr/local/autotest,/home/autotest
> +
> +[SERVER]
> +hostname: autotest
> +# Turn on RPC Logging
> +rpc_logging: False
> +# Note the user that is running the webserver has to be able to write
> +# to the below directory/file otherwise the frontend will not work with logging
> +rpc_log_path: /usr/local/autotest/logs/rpcserver.log
> +# Number of old logs to keep around
> +rpc_num_old_logs: 5
> +rpc_max_log_size_mb: 20
> +# If for some reason you don't want to rely on the Mail Transport Agent
> +# installed on this machine, you can provide an SMTP server directly here.
> +# If none provided, defaults to 'localhost', which tries to use the MTA
> +# configured on the machine to send the messages.
> +smtp_server:
> +smtp_port:
> +smtp_user:
> +smtp_password:
> +
> +[CLIENT]
> +# Drop test client caches between every test execution
> +drop_caches: True
> +# Drop test client caches between every test iteration execution
> +drop_caches_between_iterations: True
> +
> +[SCHEDULER]
> +die_on_orphans: False
> +enable_scheduler: True
> +notify_email:
> +notify_email_from:
> +notify_email_statuses: Completed,Failed,Aborted
> +max_processes_per_drone: 1000
> +max_jobs_started_per_cycle: 100
> +max_parse_processes: 5
> +max_transfer_processes: 50
> +tick_pause_sec: 5
> +clean_interval_minutes: 60
> +drones: localhost
> +drone_installation_directory: /usr/local/autotest
> +results_host: localhost
> +results_host_installation_directory:
> +secs_to_wait_for_atomic_group_hosts: 600
> +pidfile_timeout_mins: 300
> +max_pidfile_refreshes: 2000
> +
> +[HOSTS]
> +wait_up_processes:
> +default_protection: NO_PROTECTION
> +
> +[AUTOSERV]
> +# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
> +# another one based on the python SSH library paramiko (paramiko).
> +# You can change the default 'raw_ssh' to 'paramiko' if you want to.
> +ssh_engine: raw_ssh
> +# Autotest server operators *really should* set this to True, specially if
> +# using ssh_engine 'paramiko'.
> +require_atfork_module: False
> +
> +[PACKAGES]
> +serve_packages_from_autoserv: True
> diff --git a/client/shadow_config.ini b/client/shadow_config.ini
> new file mode 100644
> index 0000000..12b00a5
> --- /dev/null
> +++ b/client/shadow_config.ini
> @@ -0,0 +1,3 @@
> +#[TKO]
> +#user: autotest
> +#password: mypassword
> diff --git a/global_config.ini b/global_config.ini
> deleted file mode 100644
> index 149c4c4..0000000
> --- a/global_config.ini
> +++ /dev/null
> @@ -1,90 +0,0 @@
> -[TKO]
> -host: localhost
> -database: tko
> -db_type: mysql
> -user: autotest
> -password: please_set_this_password
> -readonly_host: localhost
> -readonly_user: nobody
> -readonly_password:
> -query_timeout: 3600
> -min_retry_delay: 20
> -max_retry_delay: 60
> -graph_cache_creation_timeout_minutes: 10
> -
> -[AUTOTEST_WEB]
> -host: localhost
> -database: autotest_web
> -db_type: mysql
> -user: autotest
> -password: please_set_this_password
> -job_timeout_default: 72
> -job_max_runtime_hrs_default: 72
> -parse_failed_repair_default: 0
> -# Only set this if your server is not 'http://[SERVER] hostname/afe/'
> -#base_url: http://your_autotest_server/afe/
> -
> -[AUTOSERV]
> -# Autotest potential install paths
> -client_autodir_paths: /usr/local/autotest,/home/autotest
> -
> -[SERVER]
> -hostname: autotest
> -# Turn on RPC Logging
> -rpc_logging: False
> -# Note the user that is running the webserver has to be able to write
> -# to the below directory/file otherwise the frontend will not work with logging
> -rpc_log_path: /usr/local/autotest/logs/rpcserver.log
> -# Number of old logs to keep around
> -rpc_num_old_logs: 5
> -rpc_max_log_size_mb: 20
> -# If for some reason you don't want to rely on the Mail Transport Agent
> -# installed on this machine, you can provide an SMTP server directly here.
> -# If none provided, defaults to 'localhost', which tries to use the MTA
> -# configured on the machine to send the messages.
> -smtp_server:
> -smtp_port:
> -smtp_user:
> -smtp_password:
> -
> -[CLIENT]
> -# Drop test client caches between every test execution
> -drop_caches: True
> -# Drop test client caches between every test iteration execution
> -drop_caches_between_iterations: True
> -
> -[SCHEDULER]
> -die_on_orphans: False
> -enable_scheduler: True
> -notify_email:
> -notify_email_from:
> -notify_email_statuses: Completed,Failed,Aborted
> -max_processes_per_drone: 1000
> -max_jobs_started_per_cycle: 100
> -max_parse_processes: 5
> -max_transfer_processes: 50
> -tick_pause_sec: 5
> -clean_interval_minutes: 60
> -drones: localhost
> -drone_installation_directory: /usr/local/autotest
> -results_host: localhost
> -results_host_installation_directory:
> -secs_to_wait_for_atomic_group_hosts: 600
> -pidfile_timeout_mins: 300
> -max_pidfile_refreshes: 2000
> -
> -[HOSTS]
> -wait_up_processes:
> -default_protection: NO_PROTECTION
> -
> -[AUTOSERV]
> -# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
> -# another one based on the python SSH library paramiko (paramiko).
> -# You can change the default 'raw_ssh' to 'paramiko' if you want to.
> -ssh_engine: raw_ssh
> -# Autotest server operators *really should* set this to True, specially if
> -# using ssh_engine 'paramiko'.
> -require_atfork_module: False
> -
> -[PACKAGES]
> -serve_packages_from_autoserv: True
> diff --git a/shadow_config.ini b/shadow_config.ini
> deleted file mode 100644
> index 12b00a5..0000000
> --- a/shadow_config.ini
> +++ /dev/null
> @@ -1,3 +0,0 @@
> -#[TKO]
> -#user: autotest
> -#password: mypassword
> --
> 1.6.2.5
>
> _______________________________________________
> Autotest mailing list
> Autotest@test.kernel.org
> http://test.kernel.org/cgi-bin/mailman/listinfo/autotest
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 15:32 ` [Autotest] " John Admanski
@ 2009-11-11 17:16   ` Lucas Meneghel Rodrigues
  2009-11-11 17:30     ` John Admanski
  0 siblings, 1 reply; 10+ messages in thread
From: Lucas Meneghel Rodrigues @ 2009-11-11 17:16 UTC (permalink / raw)
  To: John Admanski; +Cc: autotest, kvm

On Wed, 2009-11-11 at 07:32 -0800, John Admanski wrote:
> I don't think this is sufficient. It works in the simple cases, but
> what about when you're using packaging to install the clients and not
> rsync? I guess that still technically works...assuming that you
> rebuild the client package whenever you need to change the .ini.
> 
> While not strictly wrong, this solution strikes me as really
> inelegant. Its interaction with client installs is messy, and it
> changes what is a very user-facing component (the ini file) in a very
> dramatic way. At the very least we'd need to update all the
> documentation on the website that refers to the global config.

Ok, then let's revert the original patches that turn drop_caches into a
global config option. Later I will think of a more elegant solution.

> -- John
> 
> On Wed, Nov 11, 2009 at 3:24 AM, Lucas Meneghel Rodrigues
> <lmr@redhat.com> wrote:
> > So this way the client can also benefit from settings
> > defined on the configuration files.
> >
> > Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
> > ---
> >  client/common_lib/global_config.py |    4 +-
> >  client/global_config.ini           |   90 ++++++++++++++++++++++++++++++++++++
> >  client/shadow_config.ini           |    3 +
> >  global_config.ini                  |   90 ------------------------------------
> >  shadow_config.ini                  |    3 -
> >  5 files changed, 95 insertions(+), 95 deletions(-)
> >  create mode 100644 client/global_config.ini
> >  create mode 100644 client/shadow_config.ini
> >  delete mode 100644 global_config.ini
> >  delete mode 100644 shadow_config.ini
> >
> > diff --git a/client/common_lib/global_config.py b/client/common_lib/global_config.py
> > index 2bbeca0..1ced7db 100644
> > --- a/client/common_lib/global_config.py
> > +++ b/client/common_lib/global_config.py
> > @@ -10,9 +10,9 @@ from autotest_lib.client.common_lib import error
> >
> >  dirname = os.path.dirname(sys.modules[__name__].__file__)
> >  DEFAULT_CONFIG_FILE = os.path.abspath(os.path.join(dirname,
> > -                                                "../../global_config.ini"))
> > +                                                "../global_config.ini"))
> >  DEFAULT_SHADOW_FILE = os.path.abspath(os.path.join(dirname,
> > -                                                "../../shadow_config.ini"))
> > +                                                "../shadow_config.ini"))
> >
> >
> >  class ConfigError(error.AutotestError):
> > diff --git a/client/global_config.ini b/client/global_config.ini
> > new file mode 100644
> > index 0000000..149c4c4
> > --- /dev/null
> > +++ b/client/global_config.ini
> > @@ -0,0 +1,90 @@
> > +[TKO]
> > +host: localhost
> > +database: tko
> > +db_type: mysql
> > +user: autotest
> > +password: please_set_this_password
> > +readonly_host: localhost
> > +readonly_user: nobody
> > +readonly_password:
> > +query_timeout: 3600
> > +min_retry_delay: 20
> > +max_retry_delay: 60
> > +graph_cache_creation_timeout_minutes: 10
> > +
> > +[AUTOTEST_WEB]
> > +host: localhost
> > +database: autotest_web
> > +db_type: mysql
> > +user: autotest
> > +password: please_set_this_password
> > +job_timeout_default: 72
> > +job_max_runtime_hrs_default: 72
> > +parse_failed_repair_default: 0
> > +# Only set this if your server is not 'http://[SERVER] hostname/afe/'
> > +#base_url: http://your_autotest_server/afe/
> > +
> > +[AUTOSERV]
> > +# Autotest potential install paths
> > +client_autodir_paths: /usr/local/autotest,/home/autotest
> > +
> > +[SERVER]
> > +hostname: autotest
> > +# Turn on RPC Logging
> > +rpc_logging: False
> > +# Note the user that is running the webserver has to be able to write
> > +# to the below directory/file otherwise the frontend will not work with logging
> > +rpc_log_path: /usr/local/autotest/logs/rpcserver.log
> > +# Number of old logs to keep around
> > +rpc_num_old_logs: 5
> > +rpc_max_log_size_mb: 20
> > +# If for some reason you don't want to rely on the Mail Transport Agent
> > +# installed on this machine, you can provide an SMTP server directly here.
> > +# If none provided, defaults to 'localhost', which tries to use the MTA
> > +# configured on the machine to send the messages.
> > +smtp_server:
> > +smtp_port:
> > +smtp_user:
> > +smtp_password:
> > +
> > +[CLIENT]
> > +# Drop test client caches between every test execution
> > +drop_caches: True
> > +# Drop test client caches between every test iteration execution
> > +drop_caches_between_iterations: True
> > +
> > +[SCHEDULER]
> > +die_on_orphans: False
> > +enable_scheduler: True
> > +notify_email:
> > +notify_email_from:
> > +notify_email_statuses: Completed,Failed,Aborted
> > +max_processes_per_drone: 1000
> > +max_jobs_started_per_cycle: 100
> > +max_parse_processes: 5
> > +max_transfer_processes: 50
> > +tick_pause_sec: 5
> > +clean_interval_minutes: 60
> > +drones: localhost
> > +drone_installation_directory: /usr/local/autotest
> > +results_host: localhost
> > +results_host_installation_directory:
> > +secs_to_wait_for_atomic_group_hosts: 600
> > +pidfile_timeout_mins: 300
> > +max_pidfile_refreshes: 2000
> > +
> > +[HOSTS]
> > +wait_up_processes:
> > +default_protection: NO_PROTECTION
> > +
> > +[AUTOSERV]
> > +# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
> > +# another one based on the python SSH library paramiko (paramiko).
> > +# You can change the default 'raw_ssh' to 'paramiko' if you want to.
> > +ssh_engine: raw_ssh
> > +# Autotest server operators *really should* set this to True, specially if
> > +# using ssh_engine 'paramiko'.
> > +require_atfork_module: False
> > +
> > +[PACKAGES]
> > +serve_packages_from_autoserv: True
> > diff --git a/client/shadow_config.ini b/client/shadow_config.ini
> > new file mode 100644
> > index 0000000..12b00a5
> > --- /dev/null
> > +++ b/client/shadow_config.ini
> > @@ -0,0 +1,3 @@
> > +#[TKO]
> > +#user: autotest
> > +#password: mypassword
> > diff --git a/global_config.ini b/global_config.ini
> > deleted file mode 100644
> > index 149c4c4..0000000
> > --- a/global_config.ini
> > +++ /dev/null
> > @@ -1,90 +0,0 @@
> > -[TKO]
> > -host: localhost
> > -database: tko
> > -db_type: mysql
> > -user: autotest
> > -password: please_set_this_password
> > -readonly_host: localhost
> > -readonly_user: nobody
> > -readonly_password:
> > -query_timeout: 3600
> > -min_retry_delay: 20
> > -max_retry_delay: 60
> > -graph_cache_creation_timeout_minutes: 10
> > -
> > -[AUTOTEST_WEB]
> > -host: localhost
> > -database: autotest_web
> > -db_type: mysql
> > -user: autotest
> > -password: please_set_this_password
> > -job_timeout_default: 72
> > -job_max_runtime_hrs_default: 72
> > -parse_failed_repair_default: 0
> > -# Only set this if your server is not 'http://[SERVER] hostname/afe/'
> > -#base_url: http://your_autotest_server/afe/
> > -
> > -[AUTOSERV]
> > -# Autotest potential install paths
> > -client_autodir_paths: /usr/local/autotest,/home/autotest
> > -
> > -[SERVER]
> > -hostname: autotest
> > -# Turn on RPC Logging
> > -rpc_logging: False
> > -# Note the user that is running the webserver has to be able to write
> > -# to the below directory/file otherwise the frontend will not work with logging
> > -rpc_log_path: /usr/local/autotest/logs/rpcserver.log
> > -# Number of old logs to keep around
> > -rpc_num_old_logs: 5
> > -rpc_max_log_size_mb: 20
> > -# If for some reason you don't want to rely on the Mail Transport Agent
> > -# installed on this machine, you can provide an SMTP server directly here.
> > -# If none provided, defaults to 'localhost', which tries to use the MTA
> > -# configured on the machine to send the messages.
> > -smtp_server:
> > -smtp_port:
> > -smtp_user:
> > -smtp_password:
> > -
> > -[CLIENT]
> > -# Drop test client caches between every test execution
> > -drop_caches: True
> > -# Drop test client caches between every test iteration execution
> > -drop_caches_between_iterations: True
> > -
> > -[SCHEDULER]
> > -die_on_orphans: False
> > -enable_scheduler: True
> > -notify_email:
> > -notify_email_from:
> > -notify_email_statuses: Completed,Failed,Aborted
> > -max_processes_per_drone: 1000
> > -max_jobs_started_per_cycle: 100
> > -max_parse_processes: 5
> > -max_transfer_processes: 50
> > -tick_pause_sec: 5
> > -clean_interval_minutes: 60
> > -drones: localhost
> > -drone_installation_directory: /usr/local/autotest
> > -results_host: localhost
> > -results_host_installation_directory:
> > -secs_to_wait_for_atomic_group_hosts: 600
> > -pidfile_timeout_mins: 300
> > -max_pidfile_refreshes: 2000
> > -
> > -[HOSTS]
> > -wait_up_processes:
> > -default_protection: NO_PROTECTION
> > -
> > -[AUTOSERV]
> > -# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
> > -# another one based on the python SSH library paramiko (paramiko).
> > -# You can change the default 'raw_ssh' to 'paramiko' if you want to.
> > -ssh_engine: raw_ssh
> > -# Autotest server operators *really should* set this to True, specially if
> > -# using ssh_engine 'paramiko'.
> > -require_atfork_module: False
> > -
> > -[PACKAGES]
> > -serve_packages_from_autoserv: True
> > diff --git a/shadow_config.ini b/shadow_config.ini
> > deleted file mode 100644
> > index 12b00a5..0000000
> > --- a/shadow_config.ini
> > +++ /dev/null
> > @@ -1,3 +0,0 @@
> > -#[TKO]
> > -#user: autotest
> > -#password: mypassword
> > --
> > 1.6.2.5
> >
> > _______________________________________________
> > Autotest mailing list
> > Autotest@test.kernel.org
> > http://test.kernel.org/cgi-bin/mailman/listinfo/autotest
> >


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 17:16   ` Lucas Meneghel Rodrigues
@ 2009-11-11 17:30     ` John Admanski
  2009-11-11 17:35       ` Martin Bligh
  2009-11-11 23:59       ` Steve Howard
  0 siblings, 2 replies; 10+ messages in thread
From: John Admanski @ 2009-11-11 17:30 UTC (permalink / raw)
  To: Lucas Meneghel Rodrigues; +Cc: autotest, kvm, Scott Zawalski, Steve Howard

On Wed, Nov 11, 2009 at 9:16 AM, Lucas Meneghel Rodrigues
<lmr@redhat.com> wrote:
> On Wed, 2009-11-11 at 07:32 -0800, John Admanski wrote:
>> I don't think this is sufficient. It works in the simple cases, but
>> what about when you're using packaging to install the clients and not
>> rsync? I guess that still technically works...assuming that you
>> rebuild the client package whenever you need to change the .ini.
>>
>> While not strictly wrong, this solution strikes me as really
>> inelegant. Its interaction with client installs is messy, and it
>> changes what is a very user-facing component (the ini file) in a very
>> dramatic way. At the very least we'd need to update all the
>> documentation on the website that refers to the global config.
>
> Ok, then let's revert the original patches that turn drop_caches into a
> global config option. Later I will think of a more elegant solution.
>

I thought about it a bit more:

Maybe a better approach would be to have the global_config module find
the ini file in job.autodir (so on a client it would show up in the
client/ dir, and on the server in the "true" top-level dir) and then
add support to Autotest.run so that it copies over the server's copy
of the config to the client before launching a client job?

So that way it would "just work", and changes to the server config
would automatically get pushed out to client jobs. All without moving
the file that users running a server need to edit. And it's not too
complex of a design; the Autotest.run code already needs to copy over
a few files by hand like control files so copying over the config too
isn't too much of a burden.

The only concern I have is that this still might not play well with a
multi-server setup. If the servers have different configs I'm not sure
that it works all that well (although I still don't know that this
introduces any "new" problems, so I don't think it makes things any
messier in that case then they already are). I cc'ed Scott and Steve
in case they can comment on that.

-- John

>> -- John
>>
>> On Wed, Nov 11, 2009 at 3:24 AM, Lucas Meneghel Rodrigues
>> <lmr@redhat.com> wrote:
>> > So this way the client can also benefit from settings
>> > defined on the configuration files.
>> >
>> > Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
>> > ---
>> >  client/common_lib/global_config.py |    4 +-
>> >  client/global_config.ini           |   90 ++++++++++++++++++++++++++++++++++++
>> >  client/shadow_config.ini           |    3 +
>> >  global_config.ini                  |   90 ------------------------------------
>> >  shadow_config.ini                  |    3 -
>> >  5 files changed, 95 insertions(+), 95 deletions(-)
>> >  create mode 100644 client/global_config.ini
>> >  create mode 100644 client/shadow_config.ini
>> >  delete mode 100644 global_config.ini
>> >  delete mode 100644 shadow_config.ini
>> >
>> > diff --git a/client/common_lib/global_config.py b/client/common_lib/global_config.py
>> > index 2bbeca0..1ced7db 100644
>> > --- a/client/common_lib/global_config.py
>> > +++ b/client/common_lib/global_config.py
>> > @@ -10,9 +10,9 @@ from autotest_lib.client.common_lib import error
>> >
>> >  dirname = os.path.dirname(sys.modules[__name__].__file__)
>> >  DEFAULT_CONFIG_FILE = os.path.abspath(os.path.join(dirname,
>> > -                                                "../../global_config.ini"))
>> > +                                                "../global_config.ini"))
>> >  DEFAULT_SHADOW_FILE = os.path.abspath(os.path.join(dirname,
>> > -                                                "../../shadow_config.ini"))
>> > +                                                "../shadow_config.ini"))
>> >
>> >
>> >  class ConfigError(error.AutotestError):
>> > diff --git a/client/global_config.ini b/client/global_config.ini
>> > new file mode 100644
>> > index 0000000..149c4c4
>> > --- /dev/null
>> > +++ b/client/global_config.ini
>> > @@ -0,0 +1,90 @@
>> > +[TKO]
>> > +host: localhost
>> > +database: tko
>> > +db_type: mysql
>> > +user: autotest
>> > +password: please_set_this_password
>> > +readonly_host: localhost
>> > +readonly_user: nobody
>> > +readonly_password:
>> > +query_timeout: 3600
>> > +min_retry_delay: 20
>> > +max_retry_delay: 60
>> > +graph_cache_creation_timeout_minutes: 10
>> > +
>> > +[AUTOTEST_WEB]
>> > +host: localhost
>> > +database: autotest_web
>> > +db_type: mysql
>> > +user: autotest
>> > +password: please_set_this_password
>> > +job_timeout_default: 72
>> > +job_max_runtime_hrs_default: 72
>> > +parse_failed_repair_default: 0
>> > +# Only set this if your server is not 'http://[SERVER] hostname/afe/'
>> > +#base_url: http://your_autotest_server/afe/
>> > +
>> > +[AUTOSERV]
>> > +# Autotest potential install paths
>> > +client_autodir_paths: /usr/local/autotest,/home/autotest
>> > +
>> > +[SERVER]
>> > +hostname: autotest
>> > +# Turn on RPC Logging
>> > +rpc_logging: False
>> > +# Note the user that is running the webserver has to be able to write
>> > +# to the below directory/file otherwise the frontend will not work with logging
>> > +rpc_log_path: /usr/local/autotest/logs/rpcserver.log
>> > +# Number of old logs to keep around
>> > +rpc_num_old_logs: 5
>> > +rpc_max_log_size_mb: 20
>> > +# If for some reason you don't want to rely on the Mail Transport Agent
>> > +# installed on this machine, you can provide an SMTP server directly here.
>> > +# If none provided, defaults to 'localhost', which tries to use the MTA
>> > +# configured on the machine to send the messages.
>> > +smtp_server:
>> > +smtp_port:
>> > +smtp_user:
>> > +smtp_password:
>> > +
>> > +[CLIENT]
>> > +# Drop test client caches between every test execution
>> > +drop_caches: True
>> > +# Drop test client caches between every test iteration execution
>> > +drop_caches_between_iterations: True
>> > +
>> > +[SCHEDULER]
>> > +die_on_orphans: False
>> > +enable_scheduler: True
>> > +notify_email:
>> > +notify_email_from:
>> > +notify_email_statuses: Completed,Failed,Aborted
>> > +max_processes_per_drone: 1000
>> > +max_jobs_started_per_cycle: 100
>> > +max_parse_processes: 5
>> > +max_transfer_processes: 50
>> > +tick_pause_sec: 5
>> > +clean_interval_minutes: 60
>> > +drones: localhost
>> > +drone_installation_directory: /usr/local/autotest
>> > +results_host: localhost
>> > +results_host_installation_directory:
>> > +secs_to_wait_for_atomic_group_hosts: 600
>> > +pidfile_timeout_mins: 300
>> > +max_pidfile_refreshes: 2000
>> > +
>> > +[HOSTS]
>> > +wait_up_processes:
>> > +default_protection: NO_PROTECTION
>> > +
>> > +[AUTOSERV]
>> > +# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
>> > +# another one based on the python SSH library paramiko (paramiko).
>> > +# You can change the default 'raw_ssh' to 'paramiko' if you want to.
>> > +ssh_engine: raw_ssh
>> > +# Autotest server operators *really should* set this to True, specially if
>> > +# using ssh_engine 'paramiko'.
>> > +require_atfork_module: False
>> > +
>> > +[PACKAGES]
>> > +serve_packages_from_autoserv: True
>> > diff --git a/client/shadow_config.ini b/client/shadow_config.ini
>> > new file mode 100644
>> > index 0000000..12b00a5
>> > --- /dev/null
>> > +++ b/client/shadow_config.ini
>> > @@ -0,0 +1,3 @@
>> > +#[TKO]
>> > +#user: autotest
>> > +#password: mypassword
>> > diff --git a/global_config.ini b/global_config.ini
>> > deleted file mode 100644
>> > index 149c4c4..0000000
>> > --- a/global_config.ini
>> > +++ /dev/null
>> > @@ -1,90 +0,0 @@
>> > -[TKO]
>> > -host: localhost
>> > -database: tko
>> > -db_type: mysql
>> > -user: autotest
>> > -password: please_set_this_password
>> > -readonly_host: localhost
>> > -readonly_user: nobody
>> > -readonly_password:
>> > -query_timeout: 3600
>> > -min_retry_delay: 20
>> > -max_retry_delay: 60
>> > -graph_cache_creation_timeout_minutes: 10
>> > -
>> > -[AUTOTEST_WEB]
>> > -host: localhost
>> > -database: autotest_web
>> > -db_type: mysql
>> > -user: autotest
>> > -password: please_set_this_password
>> > -job_timeout_default: 72
>> > -job_max_runtime_hrs_default: 72
>> > -parse_failed_repair_default: 0
>> > -# Only set this if your server is not 'http://[SERVER] hostname/afe/'
>> > -#base_url: http://your_autotest_server/afe/
>> > -
>> > -[AUTOSERV]
>> > -# Autotest potential install paths
>> > -client_autodir_paths: /usr/local/autotest,/home/autotest
>> > -
>> > -[SERVER]
>> > -hostname: autotest
>> > -# Turn on RPC Logging
>> > -rpc_logging: False
>> > -# Note the user that is running the webserver has to be able to write
>> > -# to the below directory/file otherwise the frontend will not work with logging
>> > -rpc_log_path: /usr/local/autotest/logs/rpcserver.log
>> > -# Number of old logs to keep around
>> > -rpc_num_old_logs: 5
>> > -rpc_max_log_size_mb: 20
>> > -# If for some reason you don't want to rely on the Mail Transport Agent
>> > -# installed on this machine, you can provide an SMTP server directly here.
>> > -# If none provided, defaults to 'localhost', which tries to use the MTA
>> > -# configured on the machine to send the messages.
>> > -smtp_server:
>> > -smtp_port:
>> > -smtp_user:
>> > -smtp_password:
>> > -
>> > -[CLIENT]
>> > -# Drop test client caches between every test execution
>> > -drop_caches: True
>> > -# Drop test client caches between every test iteration execution
>> > -drop_caches_between_iterations: True
>> > -
>> > -[SCHEDULER]
>> > -die_on_orphans: False
>> > -enable_scheduler: True
>> > -notify_email:
>> > -notify_email_from:
>> > -notify_email_statuses: Completed,Failed,Aborted
>> > -max_processes_per_drone: 1000
>> > -max_jobs_started_per_cycle: 100
>> > -max_parse_processes: 5
>> > -max_transfer_processes: 50
>> > -tick_pause_sec: 5
>> > -clean_interval_minutes: 60
>> > -drones: localhost
>> > -drone_installation_directory: /usr/local/autotest
>> > -results_host: localhost
>> > -results_host_installation_directory:
>> > -secs_to_wait_for_atomic_group_hosts: 600
>> > -pidfile_timeout_mins: 300
>> > -max_pidfile_refreshes: 2000
>> > -
>> > -[HOSTS]
>> > -wait_up_processes:
>> > -default_protection: NO_PROTECTION
>> > -
>> > -[AUTOSERV]
>> > -# Autotest has 2 implementations of SSH based hosts, the default (raw_ssh), and
>> > -# another one based on the python SSH library paramiko (paramiko).
>> > -# You can change the default 'raw_ssh' to 'paramiko' if you want to.
>> > -ssh_engine: raw_ssh
>> > -# Autotest server operators *really should* set this to True, specially if
>> > -# using ssh_engine 'paramiko'.
>> > -require_atfork_module: False
>> > -
>> > -[PACKAGES]
>> > -serve_packages_from_autoserv: True
>> > diff --git a/shadow_config.ini b/shadow_config.ini
>> > deleted file mode 100644
>> > index 12b00a5..0000000
>> > --- a/shadow_config.ini
>> > +++ /dev/null
>> > @@ -1,3 +0,0 @@
>> > -#[TKO]
>> > -#user: autotest
>> > -#password: mypassword
>> > --
>> > 1.6.2.5
>> >
>> > _______________________________________________
>> > Autotest mailing list
>> > Autotest@test.kernel.org
>> > http://test.kernel.org/cgi-bin/mailman/listinfo/autotest
>> >
>
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 17:30     ` John Admanski
@ 2009-11-11 17:35       ` Martin Bligh
  2009-11-11 17:37         ` John Admanski
  2009-11-11 23:59       ` Steve Howard
  1 sibling, 1 reply; 10+ messages in thread
From: Martin Bligh @ 2009-11-11 17:35 UTC (permalink / raw)
  To: John Admanski; +Cc: Lucas Meneghel Rodrigues, autotest, kvm

> I thought about it a bit more:
>
> Maybe a better approach would be to have the global_config module find
> the ini file in job.autodir (so on a client it would show up in the
> client/ dir, and on the server in the "true" top-level dir) and then
> add support to Autotest.run so that it copies over the server's copy
> of the config to the client before launching a client job?
>
> So that way it would "just work", and changes to the server config
> would automatically get pushed out to client jobs. All without moving
> the file that users running a server need to edit. And it's not too
> complex of a design; the Autotest.run code already needs to copy over
> a few files by hand like control files so copying over the config too
> isn't too much of a burden.

Sounds good to me.

> The only concern I have is that this still might not play well with a
> multi-server setup. If the servers have different configs I'm not sure
> that it works all that well (although I still don't know that this
> introduces any "new" problems, so I don't think it makes things any
> messier in that case then they already are). I cc'ed Scott and Steve
> in case they can comment on that.

By multi-server setup, do you mean multiple copies of the autotest
server code on the same tree? Or a master with drones?

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 17:35       ` Martin Bligh
@ 2009-11-11 17:37         ` John Admanski
  2009-11-11 17:45           ` Scott Zawalski
  0 siblings, 1 reply; 10+ messages in thread
From: John Admanski @ 2009-11-11 17:37 UTC (permalink / raw)
  To: Martin Bligh; +Cc: Lucas Meneghel Rodrigues, autotest, kvm

On Wed, Nov 11, 2009 at 9:35 AM, Martin Bligh <mbligh@google.com> wrote:
>> I thought about it a bit more:
>>
>> Maybe a better approach would be to have the global_config module find
>> the ini file in job.autodir (so on a client it would show up in the
>> client/ dir, and on the server in the "true" top-level dir) and then
>> add support to Autotest.run so that it copies over the server's copy
>> of the config to the client before launching a client job?
>>
>> So that way it would "just work", and changes to the server config
>> would automatically get pushed out to client jobs. All without moving
>> the file that users running a server need to edit. And it's not too
>> complex of a design; the Autotest.run code already needs to copy over
>> a few files by hand like control files so copying over the config too
>> isn't too much of a burden.
>
> Sounds good to me.
>
>> The only concern I have is that this still might not play well with a
>> multi-server setup. If the servers have different configs I'm not sure
>> that it works all that well (although I still don't know that this
>> introduces any "new" problems, so I don't think it makes things any
>> messier in that case then they already are). I cc'ed Scott and Steve
>> in case they can comment on that.
>
> By multi-server setup, do you mean multiple copies of the autotest
> server code on the same tree? Or a master with drones?
>

I meant a master with drones. But I don't think it's a huge issue;
keeping the config in sync between all drones is already a
pre-existing issue, so however we already deal with that (or maybe we
don't, I can't remember) is independent of this suggested change, in
my mind.

-- John

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 17:37         ` John Admanski
@ 2009-11-11 17:45           ` Scott Zawalski
  2009-11-11 23:41             ` John Admanski
  0 siblings, 1 reply; 10+ messages in thread
From: Scott Zawalski @ 2009-11-11 17:45 UTC (permalink / raw)
  To: John Admanski; +Cc: Martin Bligh, autotest, kvm

On Wed, Nov 11, 2009 at 09:37, John Admanski <jadmanski@google.com> wrote:
> On Wed, Nov 11, 2009 at 9:35 AM, Martin Bligh <mbligh@google.com> wrote:
>>> I thought about it a bit more:
>>>
>>> Maybe a better approach would be to have the global_config module find
>>> the ini file in job.autodir (so on a client it would show up in the
>>> client/ dir, and on the server in the "true" top-level dir) and then
>>> add support to Autotest.run so that it copies over the server's copy
>>> of the config to the client before launching a client job?
>>>
>>> So that way it would "just work", and changes to the server config
>>> would automatically get pushed out to client jobs. All without moving
>>> the file that users running a server need to edit. And it's not too
>>> complex of a design; the Autotest.run code already needs to copy over
>>> a few files by hand like control files so copying over the config too
>>> isn't too much of a burden.
>>
>> Sounds good to me.

I like this approach also. The only real gotcha I can see (That may
not really be one) is if someone puts a global_config.ini with other
values in their client directory that is then bundled in the client
tarball. Ultimately it would be overwritten but putting something like
a warn in the section that transfers over the global_config.ini should
be enough to hint at that.

>>
>>> The only concern I have is that this still might not play well with a
>>> multi-server setup. If the servers have different configs I'm not sure
>>> that it works all that well (although I still don't know that this
>>> introduces any "new" problems, so I don't think it makes things any
>>> messier in that case then they already are). I cc'ed Scott and Steve
>>> in case they can comment on that.
>>
>> By multi-server setup, do you mean multiple copies of the autotest
>> server code on the same tree? Or a master with drones?
>>
>
> I meant a master with drones. But I don't think it's a huge issue;
> keeping the config in sync between all drones is already a
> pre-existing issue, so however we already deal with that (or maybe we
> don't, I can't remember) is independent of this suggested change, in
> my mind.

Right. However, it is still good to consider but the task ultimately
falls on the person setting up the servers. We don't do this well
internally yet but puppet is eventually planned to take care of that
for us so we basically push the config to one location that then
propagates to all parties involved. We should definitely mention this
in our documentation but my guess is that our multiserver setup is
less than documented. That is something to put on ye old documentation
TODO list.



>
> -- John
> _______________________________________________
> Autotest mailing list
> Autotest@test.kernel.org
> http://test.kernel.org/cgi-bin/mailman/listinfo/autotest
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 17:45           ` Scott Zawalski
@ 2009-11-11 23:41             ` John Admanski
  0 siblings, 0 replies; 10+ messages in thread
From: John Admanski @ 2009-11-11 23:41 UTC (permalink / raw)
  To: Scott Zawalski; +Cc: Martin Bligh, autotest, kvm, Steve Howard

For now, since the original change to use global config on the client
is causing some problem, I reverted the commit. See rev 3939. We can
put it back in once we get this sorted out.

-- John

On Wed, Nov 11, 2009 at 9:45 AM, Scott Zawalski <scottz@google.com> wrote:
> On Wed, Nov 11, 2009 at 09:37, John Admanski <jadmanski@google.com> wrote:
>> On Wed, Nov 11, 2009 at 9:35 AM, Martin Bligh <mbligh@google.com> wrote:
>>>> I thought about it a bit more:
>>>>
>>>> Maybe a better approach would be to have the global_config module find
>>>> the ini file in job.autodir (so on a client it would show up in the
>>>> client/ dir, and on the server in the "true" top-level dir) and then
>>>> add support to Autotest.run so that it copies over the server's copy
>>>> of the config to the client before launching a client job?
>>>>
>>>> So that way it would "just work", and changes to the server config
>>>> would automatically get pushed out to client jobs. All without moving
>>>> the file that users running a server need to edit. And it's not too
>>>> complex of a design; the Autotest.run code already needs to copy over
>>>> a few files by hand like control files so copying over the config too
>>>> isn't too much of a burden.
>>>
>>> Sounds good to me.
>
> I like this approach also. The only real gotcha I can see (That may
> not really be one) is if someone puts a global_config.ini with other
> values in their client directory that is then bundled in the client
> tarball. Ultimately it would be overwritten but putting something like
> a warn in the section that transfers over the global_config.ini should
> be enough to hint at that.
>
>>>
>>>> The only concern I have is that this still might not play well with a
>>>> multi-server setup. If the servers have different configs I'm not sure
>>>> that it works all that well (although I still don't know that this
>>>> introduces any "new" problems, so I don't think it makes things any
>>>> messier in that case then they already are). I cc'ed Scott and Steve
>>>> in case they can comment on that.
>>>
>>> By multi-server setup, do you mean multiple copies of the autotest
>>> server code on the same tree? Or a master with drones?
>>>
>>
>> I meant a master with drones. But I don't think it's a huge issue;
>> keeping the config in sync between all drones is already a
>> pre-existing issue, so however we already deal with that (or maybe we
>> don't, I can't remember) is independent of this suggested change, in
>> my mind.
>
> Right. However, it is still good to consider but the task ultimately
> falls on the person setting up the servers. We don't do this well
> internally yet but puppet is eventually planned to take care of that
> for us so we basically push the config to one location that then
> propagates to all parties involved. We should definitely mention this
> in our documentation but my guess is that our multiserver setup is
> less than documented. That is something to put on ye old documentation
> TODO list.
>
>
>
>>
>> -- John
>> _______________________________________________
>> Autotest mailing list
>> Autotest@test.kernel.org
>> http://test.kernel.org/cgi-bin/mailman/listinfo/autotest
>>
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 17:30     ` John Admanski
  2009-11-11 17:35       ` Martin Bligh
@ 2009-11-11 23:59       ` Steve Howard
  2009-11-12  0:09         ` Lucas Meneghel Rodrigues
  1 sibling, 1 reply; 10+ messages in thread
From: Steve Howard @ 2009-11-11 23:59 UTC (permalink / raw)
  To: John Admanski; +Cc: Lucas Meneghel Rodrigues, autotest, kvm, Scott Zawalski

On Wed, Nov 11, 2009 at 9:30 AM, John Admanski <jadmanski@google.com> wrote:
> I thought about it a bit more:
>
> Maybe a better approach would be to have the global_config module find
> the ini file in job.autodir (so on a client it would show up in the
> client/ dir, and on the server in the "true" top-level dir) and then
> add support to Autotest.run so that it copies over the server's copy
> of the config to the client before launching a client job?
>
> So that way it would "just work", and changes to the server config
> would automatically get pushed out to client jobs. All without moving
> the file that users running a server need to edit. And it's not too
> complex of a design; the Autotest.run code already needs to copy over
> a few files by hand like control files so copying over the config too
> isn't too much of a burden.

For the record, I agree with John's proposed approach.

Steve

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [Autotest] [PATCH] Move global configuration files to client dir
  2009-11-11 23:59       ` Steve Howard
@ 2009-11-12  0:09         ` Lucas Meneghel Rodrigues
  0 siblings, 0 replies; 10+ messages in thread
From: Lucas Meneghel Rodrigues @ 2009-11-12  0:09 UTC (permalink / raw)
  To: Steve Howard; +Cc: John Admanski, autotest, kvm, Scott Zawalski

On Wed, 2009-11-11 at 15:59 -0800, Steve Howard wrote:
> On Wed, Nov 11, 2009 at 9:30 AM, John Admanski <jadmanski@google.com> wrote:
> > I thought about it a bit more:
> >
> > Maybe a better approach would be to have the global_config module find
> > the ini file in job.autodir (so on a client it would show up in the
> > client/ dir, and on the server in the "true" top-level dir) and then
> > add support to Autotest.run so that it copies over the server's copy
> > of the config to the client before launching a client job?
> >
> > So that way it would "just work", and changes to the server config
> > would automatically get pushed out to client jobs. All without moving
> > the file that users running a server need to edit. And it's not too
> > complex of a design; the Autotest.run code already needs to copy over
> > a few files by hand like control files so copying over the config too
> > isn't too much of a burden.
> 
> For the record, I agree with John's proposed approach.

Yes, I am preparing a patch using John's idea, will send it tomorrow
morning.

Thanks guys,

> Steve


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2009-11-12  0:10 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-11 11:24 [PATCH] Move global configuration files to client dir Lucas Meneghel Rodrigues
2009-11-11 15:32 ` [Autotest] " John Admanski
2009-11-11 17:16   ` Lucas Meneghel Rodrigues
2009-11-11 17:30     ` John Admanski
2009-11-11 17:35       ` Martin Bligh
2009-11-11 17:37         ` John Admanski
2009-11-11 17:45           ` Scott Zawalski
2009-11-11 23:41             ` John Admanski
2009-11-11 23:59       ` Steve Howard
2009-11-12  0:09         ` Lucas Meneghel Rodrigues

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox