Merge branch 'master' into exp2
[sfa.git] / docs / sfa-debian-installfromscratch.txt
1 Install on debian without prior myplc install
2
3 apt-get install python-openssl python-m2crypto python-dateutil python-lxml  python-libxml2 python-libxslt1 python-pygresql python-psycopg2 python-zsi 
4 easy_install xmlbuilder   
5 apt-get install xmlsec1 libxmlsec1-dev (not sure about latter)
6 /etc/postgresql/8.4/main/pg_hba.conf
7
8
9 planetlab-europe-01:/etc/sfa/configs# su postgres
10 postgres@planetlab-europe-01:/etc/sfa/configs$ psql -d template1
11 template1=# create user pgsqluser password 'XXX';
12 ou ALTER USER pgsqluser WITH PASSWORD 'XXX';
13 template1=# create database planetlab5;
14 template1=# grant all on database planetlab5 to pgsqluser;
15
16 scp root@dev.top-hat.info:/etc/init.d/functions: /etc/init.d
17 planetlab-europe-01:~/jordan/sfa# scp root@dev.top-hat.info:/usr/bin/plc-config* /usr/bin
18 plc-config
19 plc-config-tty
20
21 scp root@dev.top-hat.info:/sbin/consoletype /sbin
22
23 scp root@dev.top-hat.info:/usr/lib/python2.5/site-packages/plc_config.py /usr/lib/python2.5/site-packages/
24 ou
25 scp root@dev.top-hat.info:/usr/lib/python2.5/site-packages/plc_config.py /usr/lib/python2.6/
26
27 mkdir /var/lock/subsys
28
29 mkdir /etc/planetlab
30 scp root@dev.top-hat.info:/etc/planetlab/plc_config /etc/planetlab
31
32 harcoded in /etc/init.d/sfa
33 planetlab-europe-01:~# ln -s /usr/local/bin/sfa-server.py /usr/bin
34 planetlab-europe-01:~# ln -s /usr/local/bin/gen-sfa-cm-config.py /usr/bin
35 planetlab-europe-01:~# ln -s /usr/local/bin/sfa_flashpolicy.py /usr/bin
36
37 * when starting sfa without the import...
38 IOError: [Errno 2] No such file or directory: '/var/lib/sfa/authorities/server.key'
39 2011-06-03 20:12:21,086 - CRITICAL - SFA server is exiting END TRACEBACK
40
41 THINK OF NAMING RESOURCES FOR NEW TESTBED
42
43 packages installed in ./local/lib/python2.6/dist-packages/sfa/
44
45 mkdir /var/log/httpd for crashlog
46 ln -s /usr/local/bin/keyconvert.py /usr/bin
47
48 ISSUES RESOLVED
49
50 planetlab-europe-01:~/jordan/sfa# sfa-config-tty 
51 Traceback (most recent call last):
52  File "/usr/local/bin/sfa-config-tty", line 5, in 
53    import plc_config
54 ImportError: No module named plc_config
55
56 util/server.py has a dependency on plc !!!!!!!!
57
58 util/api.py +146
59       self.logger=sfa_logger() # XXX jordan missing ()
60
61 baseAPI
62     fill_record_info
63
64 getDelegatedCredential
65
66
67
68 --------------------------------------------------------------------------------
69
70
71 planetlab-europe-01:/etc/sfa# /etc/init.d/sfa restart
72 /etc/init.d/sfa: line 17: /etc/init.d/functions: No such file or directory
73 /etc/init.d/sfa: line 88: action: command not found
74 /etc/init.d/sfa: line 34: plc-config: command not found
75 SFA: Warning: Invalid configuration file(s) detected
76 Traceback (most recent call last):
77  File "/usr/local/bin/gen-sfa-cm-config.py", line 9, in 
78    sfa_config = SfaConfig()
79  File "/usr/local/lib/python2.6/dist-packages/sfa/util/config.py", line 33, in __init__
80    self.load(config_file)
81  File "/usr/local/lib/python2.6/dist-packages/sfa/util/config.py", line 79, in load
82    raise IOError, "Could not find the configuration file: %s" % config_file
83 IOError: Could not find the configuration file: /etc/sfa/sfa_config.py
84 touch: cannot touch `/var/lock/subsys/sfa-server.py': No such file or directory