Post หน่อยดีกว่า นานแล้ว :)

เอางานมาแปะ

- cnap 10 chapters ทำไปได้แค่ 2
- SE presentation ทำ preliminary presentation material ไปแล้ว เหลือทำให้ดีขึ้นอีก ส่วนตัว paper ยังไม่ได้จากชัยเลยไม่รู้ว่าเป็นยังไง
- PM report paper ตกลงทำ redhat : opensource project management case study
- PM quiz ยังไม่ได้แตะ
- web service — ทำ exercise ให้หมด สรุปเนื้อหาที่เรียนด้วย

Posted in life | Leave a comment

Table Books

isbn varchar 20
title varchar 70
author varchar 50
price float -

DROP TABLE IF EXISTS `test`.`books`;
CREATE TABLE  `test`.`books` (
`isbn` varchar(20) NOT NULL,
`title` varchar(70) NOT NULL,
`author` varchar(50) NOT NULL,
`price` float NOT NULL,
PRIMARY KEY  (`isbn`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

Posted in Uncategorized | Leave a comment

Mounting NFS at boot automatically on Solaris10 x86

1. add the mount entry in /etc/vfstab

2. check if disabled or not
svcs nfs/client
if disabled then enable it

3. svcadm enable  svc:/network/nfs/client:default

Posted in sysadmin | Tagged , , | Leave a comment

I could , could sing of your love forever :)

Hello dude , today I  start the  warm saturday morning with a very very good feeling after finishing the midterm examination.

Yes, absolutely have been the hard time for me. Last Night, I slept on my dearest bed for 6 hours

and I wake up on 5.30 am.

I spend my morning time on googling and watching the hot stuffs on youtube.com
and I found this one : I could sing of your love forever
which  composed by Martin Smith and perform by Delirious? Band :

yes , It’s one of religious songs.
I love it at the first heard , dude
and now I am listening to  it repeatly.

I want you to hear about it. :)

here , its lyric :)

I Could Sing Of Your Love Forever

Over the mountains and the sea,
Your river runs with love for me,
and I will open up my heart
and let the Healer set me free.
I’m happy to be in the truth,
and I will daily lift my hands:
for I will always sing of when
Your love came down. [Yeah!]

I could sing of Your love forever,
I could sing of Your love forever,
I could sing of Your love forever,
I could sing of Your love forever. [Repeat]

Oh, I feel like dancing -
it’s foolishness I know;
but, when the world has seen the light,
they will dance with joy,
like we’re dancing now.

Written by Martin Smith  1994 Curious Music UK

I could sing of your love forever

Posted in Uncategorized | 2 Comments

HTTPD mod_perl & mod_cgi

1. install mod_perl , mod_cgi

#yum -y install mod_perl mod_cgi

2. edit /etc/httpd/conf/httpd.conf

#vi /etc/httpd/conf/httpd.conf

LoadModule cgi_module modules/mod_cgi.so
LoadModule perl_module modules/mod_perl.so

3. edit /etc/httpd/conf/vhost.conf to handle cgi/perl
#vi /etc/httpd/conf/vhost.conf

<Directory “/path/to/your/perl-script-dir”>
AllowOverride all
DirectoryIndex index.php index.html
Options +ExecCGI
AddHandler cgi-script cgi pl

Order allow,deny
Allow from all
</Directory>

4. reload your httpd server

#service httpd reload

5. test to execute perl script by httpd

#cd /path/to/your/perl-script/dir
#vi test.pl

#!/usr/bin/perl
print “Content-type: text/plain\r\n\r\n”;
print “mod_perl rules!\n”;

6. chmod +x to tes.pl and test to run perl on the shell

#chmod +x test.pl
#perl ./test.pl

Content-type: text/plain

mod_perl rules!

7. go to your browser
http://hostname/path/to/your/perl-script-dir/test.pl

Content-type: text/plain

mod_perl rules!

Posted in sysadmin | Tagged , , , , , , | Leave a comment

SMF Repository Restore

#/lib/svc/bin/restore_repository

choose the backup

Posted in sysadmin | Tagged , , , | 1 Comment

glassfish on opensolaris

Probably I can install Tomcat by downloading it from the Tomcat site, unpack it, and run it, but I don’t want to do this: I’d rather use the OpenSolaris packaging system. However, it seems there isn’t a package available for Tomcat. Atleast, I haven’t found it. So, my initial thought was to install JBoss instead. I’ve good experiences with JBoss, and for me, JBoss is a good replacement (or superset) for Tomcat. However, I also couldn’t find a proper download for this. So, why not install GlassFish then?

I’ve never worked with GlassFish before, but installing and configuring wasn’t a problem at all. I just followed the instructions I found here, and did the following steps:

1) pkg set-authority -O http://pkg.opensolaris.org:80 opensolaris.org
2) pkg refresh
3) pkg install glassfishv2
4) Then run the command to create a default domain1/usr/appserver/bin/asadmin create-domain –user admin –adminport 4848 domain1

During the creation of new domain
a)type (typical default) admin password : adminadmin
b)type (typical default) master password : changeit

5) Then run the command to start the newly created default domain1
/usr/appserver/bin/asadmin start-domain –user admin domain1

6) Now you should be able to access the GlassFishv2 on OpenSolaris

GlassFish Admin Console
http://hostname_or_ip_address:4848

GlassFish HTTP
http://hostname_or_ip_address:8080
https://hostname_or_ip_address:8181

And it all worked. I love when things just work!

Posted in Uncategorized | Tagged , | Leave a comment

lsb_release : to print out the ubuntu release information

#lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 7.04
Release:        7.04
Codename:       feisty

Posted in sysadmin | Tagged , | Leave a comment

น่าคิดดีนะ

Posted in sysadmin | Tagged | 1 Comment

Setting up NTP Client on CentOS 5.3

setting up the ntp client for time synchronization on centos cando as follow

1. login to your shell as root

2. install ntp client by invoke this command
yum -y install ntp
3. edit ntp file configuration|
vi /etc/ntp.conf
comment out all the default time server and add your own time server. in case of me , Im in Thailand
so I use the time server that located in thailand.

server  clock.thaicert.org
server  time1.nimt.or.th
server  time2.nimt.or.th
server  time3.nimt.or.th

5. start the service

service ntpd start

6. start ntp on boot
chkconfig –levels 235 ntpd on

Posted in sysadmin | Tagged , , | 1 Comment
  • Tags

  • Pages

  • Categories

  • Archives