./configure --prefix=$PREFIX \ --enable-ssl \ --enable-so \ --enable-mods-shared="status info" \ --with-ssl=/usr \ --with-mpm=worker \ |
#!/bin/sh SRC_BASE=/tmp/httpd-2.0.49 PREFIX=/usr/local/apache2 HTTP_CONF=/conf BACKUP_DIR=/home/backup/httpd # set PREFIX of Open SSL # For FreeBSD, confirm it # by "Makefile" of Open SSL # (/usr/ports/security/openssl/Makefile) OPEN_SSL="/usr" DATE=`date "+%Y%m%d%H%M%S"` #backup httpd configuration file if [ -d ${PREFIX}${HTTP_CONF} ] then echo "backup apache2's configuraton files" cd ${PREFIX}${HTTP_CONF} tar -zcvf "$BACKUP_DIR/httpd_conf${DATE}.tar.gz" ./* if [ $? -ne 0 ]; then (echo "error at backup";exit) fi fi # change current directory cd $SRC_BASE echo "curren directory is `pwd`" # execute configure echo "execute configure" ./configure --prefix=$PREFIX \ --enable-ssl \ --enable-so \ --enable-mods-shared="status info" \ --with-ssl=$OPEN_SSL \ --with-mpm=worker \ 2>&1 | tee configure.log; if [ $? -ne 0 ]; then (echo "error at configure";exit) fi # compile apache2 echo "execute make" make clean && make if [ $? -ne 0 ]; then (echo "error at make";exit) fi # install apache2 echo "execute make install" make install if [ $? -ne 0 ]; then (echo "error at make";exit) fi |
#!/usr/bin/perl # # Check ip address, and update DDNS for "ddo.jp" # # # parameters # "ddo.jp" ID & PASSWD local $ID = 'xxxxxxxxxx'; # Login ID(It serves as a domain name) local $PASSWD = 'xxxxxxxxxx'; # Login password # file names local $CRT_IPF = '/tmp/CRT_IP2.dat'; local $LOG = '/var/log/ddns.log'; # Check current ip address on the appointed URL web page. local $CHK_URL="http://info.ddo.jp/remote_addr.php"; # local $INTERVAL = 1209600; # 2 weeks # $ENV{'PATH'}="/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin"; #--------------------------------------------------- # main my ($NEW_IP,$CRT_IP,$CRT_TIME,$i); # get current ip address which set as the domain. $CRT_IP = ""; $CRT_TIME = "0"; open(INPUT, $CRT_IPF); foreach(<INPUT>){ chop; /^IP:/ && do{ $CRT_IP = $' }; /^TIME:/ && do{ $CRT_TIME = $' }; } close(INPUT); # check a assigned ip address open(INPUT, "lynx -dump \"$CHK_URL\" | "); foreach(<INPUT>){ /([0-9\.].*)/ && do{ $NEW_IP = $1}; } close(INPUT); # Lapsed time from the last update $i = time() - $CRT_TIME; # change DDNS, supposing the IP address is changed. if ( ( ($NEW_IP ne "" )&&($CRT_IP ne $NEW_IP) ) || ( $i > $INTERVAL) ) { # change DDNS open(INPUT2, "lynx -dump \"http://ddo.jp/dnsupdate.php?dn=$ID&ip=$NEW_IP&pw=$PASSWD\" |"); # check whether change of DDNS has been successful foreach(<INPUT2>){ /SUCCESS: / && do{ $TEMP = 1;}; } if( $TEMP == 1){ # save a new IP address. $i = time(); open (OUTPUT ,">$CRT_IPF"); print OUTPUT "IP:$NEW_IP\nTIME:$i\n"; close OUTPUT; # write a message on the log file $time = conv_date(time()); open(LOG, ">> $LOG"); print(LOG $time . ":change \"" . $ID . ".ddo.jp\" <= " . $NEW_IP . "\n"); close(LOG); } } sub conv_date{ my ($times,$mode) = @_; my ($sec,$min,$hour,$mday,$month,$year,$wday); ($sec,$min,$hour,$mday,$month,$year,$wday,undef,undef) = localtime($times); $month++; $year += 1900; $times = sprintf("%d/%02d/%02d %02d:%02d", $year, $month, $mday, $hour, $min); return($times); } |
| ¢¨1 | ¤ï¤¶¤ï¤¶VMware palyer¤Ç¤Ê¤¯¤Æ¤â¡¢VMware saver¤â̵½þÄ󶡤µ¤ì¤Æ¤¤¤ë¤Î¤Ç¡¢¤½¤Ã¤Á¤ò»È¤¦¤Û¤¦¤¬¼ê¤Ã¼è¤êÁᤤ¡£¤¿¤À¤·»ÈÍѤ¹¤ë¤¿¤á¤Ë¤Ï¡¢¥æ¡¼¥¶ÅÐÏ¿¤·¥é¥¤¥»¥ó¥¹¤ò¼èÆÀ¤¹¤ëɬÍפ¬¤¢¤ë¡£ ->VMware server |
| ¢¨2 | ¤Þ¤¿VMware palyer¤Ç¤â¡¢ÍÑÅÓÊ̤ÎVM¤¬Â·¤Ã¤Æ¤¤¤ë¤Î¤Ç¤½¤ì¤ò¤½¤Î¤Þ¤ÞÍøÍѤ¹¤ë¼ê¤â¤¢¤ë¡£ ¢ªVM¤Ï¤³¤Á¤é |