When a user is created it is locked, which shows in the shadow file with a *LK* in the password field and a result of LK when you run passwd -s against it. When an account is locked, cron will not run for it. The way to fix that without giving the account a password is to set it to be a non-login account. You can change *LK* in the shadow file to NP for "No Password" which will change the passwd -s output to NL for non-login. That way the user still can't login, but it can run cron.
The reason I would want something like that is so that there is no way to do a password attack against the apache or mysql users, and yet I can set up a crontab to run as those users. Particularly useful when setting up mysql backups/dumps.
Wednesday, August 18, 2010
Thursday, August 5, 2010
adding an application to smf in solaris 10
create the method file in /lib/svc/method, usually easiest to find something close to the app you're installing and modify the file. For example apache2 comes installed, but I put the latest version in /usr/local/apache2 so I just use the files that are already there with path modifications.
Then you need to add a manifest. Those are stored in /var/svc/manifest and usually if you're adding your own you would put it in the /var/svc/manifest/site directory (or so I've heard). Again the best way is to get one that is close and modify it or use it as a template. I've found that the one installed with the system works just fine with an upgraded version of apache in /usr/local/apache2 but best to check to be sure.
Then you import it:
svccfg -v import /var/svc/manifest/site/http-apache2.xml
Then the normal SMF controls should work for it.
Then you need to add a manifest. Those are stored in /var/svc/manifest and usually if you're adding your own you would put it in the /var/svc/manifest/site directory (or so I've heard). Again the best way is to get one that is close and modify it or use it as a template. I've found that the one installed with the system works just fine with an upgraded version of apache in /usr/local/apache2 but best to check to be sure.
Then you import it:
svccfg -v import /var/svc/manifest/site/http-apache2.xml
Then the normal SMF controls should work for it.
Monday, August 2, 2010
creating solaris zones
This is the basic set of commands to create a whole-root zone (a zone that does not share drives with the global)
[root@stamp zones]# zonecfg -z dplweb
dplweb: No such zone configured
Use 'create' to begin configuring a new zone.
zonecfg:dplweb> create -b
zonecfg:dplweb> set zonepath=/opt/zones/dplweb
zonecfg:dplweb> set autoboot=true
zonecfg:dplweb> add net
zonecfg:dplweb:net> set address=xxx.xxx.xxx.xxx
zonecfg:dplweb:net> set physical=eth0
zonecfg:dplweb:net> set defrouter=xxx.xxx.xxx.xxx
zonecfg:dplweb:net> end
zonecfg:dplweb> verify
zonecfg:dplweb> commit
Plumb the nic for the zone
ifconfig nge1 plumb
Then use zoneadm to install the zone
zoneadm -z dplweb install
Then start that puppy up.
zoneadm -z dplweb boot
Then you'll have to login to the console to finish installation.
zlogin -C dplweb
[root@stamp zones]# zonecfg -z dplweb
dplweb: No such zone configured
Use 'create' to begin configuring a new zone.
zonecfg:dplweb> create -b
zonecfg:dplweb> set zonepath=/opt/zones/dplweb
zonecfg:dplweb> set autoboot=true
zonecfg:dplweb> add net
zonecfg:dplweb:net> set address=xxx.xxx.xxx.xxx
zonecfg:dplweb:net> set physical=eth0
zonecfg:dplweb:net> set defrouter=xxx.xxx.xxx.xxx
zonecfg:dplweb:net> end
zonecfg:dplweb> verify
zonecfg:dplweb> commit
Plumb the nic for the zone
ifconfig nge1 plumb
Then use zoneadm to install the zone
zoneadm -z dplweb install
Then start that puppy up.
zoneadm -z dplweb boot
Then you'll have to login to the console to finish installation.
zlogin -C dplweb
Saturday, July 31, 2010
July solar generation
New totals!
8097 watts max
8.04mwh generated for a total of 1080 for this month.
8097 watts max
8.04mwh generated for a total of 1080 for this month.
Friday, July 30, 2010
solaris partitioning and some random info
The network management ports on solaris servers are usually 100mb full connections.
The network management gui is quite useful for updating the ILOM/bios/firmware and is a good place to find the serial number.
As of Solaris 10 U8 10/09 the partitioning I'm using is:
12gb /
12gb /var
256 mb for metadata slice
and then I put everthing else in the /opt slice because that's where I store my localzones and downloads.
I set up swap equal to twice the memory installed
The solaris default install that comes on the hardware is set up with very little swap and about the same / as I set up, but nothing set aside for /var or /opt. They leave a good deal of space unallocated though so it's always easy to add more partitions.
Using the install option of turning off network services really helps lock down a new solaris server. I've found that to be quite useful.
The network management gui is quite useful for updating the ILOM/bios/firmware and is a good place to find the serial number.
As of Solaris 10 U8 10/09 the partitioning I'm using is:
12gb /
12gb /var
256 mb for metadata slice
and then I put everthing else in the /opt slice because that's where I store my localzones and downloads.
I set up swap equal to twice the memory installed
The solaris default install that comes on the hardware is set up with very little swap and about the same / as I set up, but nothing set aside for /var or /opt. They leave a good deal of space unallocated though so it's always easy to add more partitions.
Using the install option of turning off network services really helps lock down a new solaris server. I've found that to be quite useful.
Wednesday, July 28, 2010
New SCiB battery is really impressive.
http://www.scib.jp/en/
They claim 6000+ cycles without harm and 90% recharge in 5 minutes.
Nominal Voltage 12V
Nominal Capacity 4.0Ah
Max. Charging Current 8.4A
Max. Discharging Current 8.0A (continuous)
25A (within0.3s)
Size Approx. 145 x 109 x 48mm
Weight Approx. 1.0kg
Damn...that's impressive.
They claim 6000+ cycles without harm and 90% recharge in 5 minutes.
Nominal Voltage 12V
Nominal Capacity 4.0Ah
Max. Charging Current 8.4A
Max. Discharging Current 8.0A (continuous)
25A (within0.3s)
Size Approx. 145 x 109 x 48mm
Weight Approx. 1.0kg
Damn...that's impressive.
Wednesday, July 14, 2010
New lower 1BOG solar prices!
1BoG has negotiated new even lower discounts for solar installations in Denver. 15% lower than the the price I paid last year. That is too awesome, although I certainly wish I could get that deal retroactively.
Or at least get a monitor for my system.
Or at least get a monitor for my system.
Subscribe to:
Posts (Atom)
