Wednesday, May 16, 2012

cvs Permission denied

Error message:
Logging in to :pserver:wu@172.22.113.181:2401/cvs
CVS password: 
[zh@localhost ~]$ rm -rf DRS-1.0/
[zh@localhost ~]$ cvs checkout -r flbranch DRS-1.0
cvs checkout: failed to create lock directory for `/cvs/DRS-1.0' (/cvs/DRS-1.0/#cvs.lock): Permission denied
cvs checkout: failed to obtain dir lock in repository `/cvs/DRS-1.0'
cvs [checkout aborted]: read lock failed - giving up

Solution:
Need to add user to cvs group
[root@NTRCVS ~]# usermod -a -G cvs wu
[root@NTRCVS ~]# id wu
uid=501(wu) gid=501(wu) groups=501(wu),502(cvs)
 

Tuesday, May 15, 2012

Move CVS

Instruction for Move CVS to different box or backup CVS - CentOS

1,  install CVS
 yum install cvs

2, create cvs group and user
useradd -G cvs cvs

3, set CVSROOT environment variable

CVSROOT=/cvs/CVSROOT/
export CVSROOT

4, generate CVSROOT
cvs -d /cvs/CVSROOT init

5 setup the CVS server. It will be launched by Xinetd
[root@NTRCVS ~]# vim /etc/xinetd.d/cvs
# default: off
# description: The CVS service can record the history of your source \
#              files. CVS stores all the versions of a file in a single \
#              file in a clever way that only stores the differences \
#              between versions.
service cvspserver
{
        disable                 = no
        port                    = 2401
        socket_type             = stream
        protocol                = tcp
        wait                    = no
        user                    = root
        passenv                 = PATH
        server                  = /usr/bin/cvs
        env                     = HOME=/cvs
        server_args             = -f --allow-root=/cvs pserver
#       bind                    = 127.0.0.1
}



6,run cvs server
/etc/init.d/xinetd restart





Monday, April 30, 2012

Saturday, April 14, 2012

install cuckoo in ubuntu

http://www.joshuagauthier.com/2011/07/

http://cuckoobox.org/doc/0.1/setup.html#basic_setup_intall_controller_requirements

http://www.cuckoobox.org/doc/0.3.2/html/introduction/sandboxing.html#using-a-sandbox

http://www.cuckoobox.org/doc/0.3.2/html/installation/host/configuration.html

Thursday, April 12, 2012

avg linux install - rpm

http://free.avg.com/us-en/download.prd-alf

rpm -i avg2012flx-r1786-a4748.i386.rpm

start avg
/etc/init.d/avgd start

install clamav in CentOS

1, Download source package
http://sourceforge.net/projects/clamav/files/clamav/0.97.4/clamav-0.97.4.tar.gz/download

2, create clamav group and user
[root@localhost clamav-0.97.4]#groupadd clamav
[root@localhost clamav-0.97.4]#adduser -g clamav clamav

3, Unzip file and install
tar zxvf clamav-0.97.4.tar.gz
cd clamav-0.97.4
./configure
make
make install

4, update clamav DB
a, create update log file
vim /var/log/freshclam.log
chown clamav:clamav /var/log/freshclam.log
b, config configure file
vim /usr/local/etc/freshclam.conf
# Comment or remove the line below.
#Example

# Path to the database directory.
# WARNING: It must match clamd.conf's directive!
# Default: hardcoded (depends on installation options)
#DatabaseDirectory /var/lib/clamav

DatabaseDirectory /usr/local/share/clamav

# Path to the log file (make sure it has proper permissions)
# Default: disabled

UpdateLogFile /var/log/freshclam.log

# Maximum size of the log file.
# Value of 0 disables the limit.
# You may use 'M' or 'm' for megabytes (1M = 1m = 1048576 bytes)
# and 'K' or 'k' for kilobytes (1K = 1k = 1024 bytes).
# in bytes just don't use modifiers.
# Default: 1M
LogFileMaxSize 2M

# Log time with each message.
# Default: no
LogTime yes

# Enable verbose logging.
# Default: no
LogVerbose yes

# Use system logger (can work together with UpdateLogFile).
# Default: no
LogSyslog yes

5, update clamav DB - you can add this in the cronjob
/usr/local/bin/freshclam

6, DB folder
[root@localhost ~]# ll /usr/local/share/clamav
total 33524
-rw-r--r-- 1 clamav clamav 59546 Apr 12 14:54 bytecode.cvd
-rw-r--r-- 1 clamav clamav 3461818 Apr 12 14:54 daily.cvd
-rw-rw-r-- 1 clamav clamav 30750647 Apr 12 14:13 main.cvd
-rw------- 1 clamav clamav 468 Apr 12 14:54 mirrors.dat