Operating System/Solaris2007/08/09 12:34

23장. System관련 Technique (&Tip)

23.1 Large dummy file 생성 방법

dd를 이용한 Create large files

Systax :
dd if=file of=file bs=n count=n

examples : 아래의 예는 100Mbyte의 dummy file을 만든다.

  [dct:/tmp]# dd if=/dev/zero of=100megs bs=10000 count=10000

  10000+0 records in
  10000+0 records out

  [dct:/tmp]# ls -al 100megs

  -rw-r--r--  1 root    other   100000000 10월 20일 17:34 100megs

  [sun:/tmp]#

  ; bs - Buffer에 확보될 block size
    count - bs에서 설정된 size의 buffer를 dummy file로 copy할 횟수
    위의 예는 10000block을 10000번 copy하여 100Mbyte의 bummy file을 생성한다.

23.2 DOS file에서 ^M 문자 제거 방법

아래 예는 간혹 DOS에서 편집된 Text File을 Unix machine에서 열 경우 각 line 끝에 ^M를 볼 수 있는데, 이를 제거할 수 있는 방법 3가지를 보여준다

1) tr을 이용한 제거 방법

  Syntax : tr -d string < infile > outfile
  dct# tr -d "\015" < /tmp/hosts.dos > /tmp/hosts.unix

2) sed을 이용한 제거 방법

  Syntax : sed 's/[regular expression]/[Replacement]/[flags]/g' infile > outfile
  dct# sed 's/^V^M//g' /tmp/hosts.dos > /tmp/hosts.unix

3) vi 편집기를 이용한 방법

  dct# vi /tmp/hosts.dos 열리면, vi command line상에서 아래와 같이 한다.

  :%s/^V^M//g

23.3 두 개의 Monitor에 Open Windows 올릴 때 (2가지 방법)

openwin -dev /dev/fbb/?? -dev /dev/fbb/??

openwin -dev /dev/fbb/??
openwin -dev /dev/fbb/??

23.4 rdist 사용하여 정해진 시간에 file transfer

rdist - remote file distribution program

rdist 명령어를 사용하기 위해서는 /etc/hosts.equiv file과 /.rhosts file을 원하는 host와 사용자에 맞게 editing하여 주어야 한다.

remote file transfer를 위해서는 각각의 System에 /etc/hosts.equiv file을 만들어 각각의 System을 명명하여 주거나, +라고 써주어 모든 System에서 수행하는 r명령어 (rcp, rsh, rlogin, rdist...)에 대해 open을 시켜주어야 한다. 또는 각각의 사용자 Home Directory에 .rhosts file을 만들어야 한다.

rdist에는 여러 가지 option이 있다. 이러한 option들은 "man rdist"를 수행하면 살펴볼 수 있는데, 정해진 시간에 File을 전송하면서 세부적인 사항을 미리 선택하기 위해서는 '-f' option을 사용하는 것이 좋다.

여기에서는 실제로 rdist command를 사용하여 file transfer하는 예를 보기로 하겠다.

source host     = TECH
destination host = sun

1. 먼저 TECH의 /etc/hosts.equiv file을 편집.

        www
        cello   
        mymy
        sun      (여기에서는 기존의 entry에 hyundai2를 추가함. 다른 것 없이 그냥 +만 써넣어도 됨)

2. /.rhosts file등에도 다음과 같이 하여준다.

+
+ sms

3. 그리고 만일 eng라는 Directory를 transfer하려고 할 때, 막상 transfer하고 보면 eng라는 parent directory는 보이지 않고 그 안의 sub directory만이 보이게 된다. 즉, 나는 /eng라는 이름과 함께 그 밑의 sub directory인 words, toeic, read등을 transfer하려 한다면 target이 되는 System의 원하는 위치에 eng라는 이름의 Directory를 만들어 두는 것이 편하다는 것이다.

4. description file을 작성한다.

 다음은 sms라는 사용자가 remote system상의 sms에게 file을 transfer하는 것이다. 이 File의 이름은 사용자 임의로 주어도 된다. 이 예에서 description file의 이름은 distfile이다.

        HOSTS = ( sms@sun ) --> hostname만 써넣어도 된다.
        FILES = (/user1/sms/eng) --> transfer하기 원하는 File의 위치

        ${FILES} -> ${HOSTS}

        install -R ~sms/eng;    --> transfer된 File을 install하기 원하는 위치
        except (/user1/sms/eng/toeic); --> transfer를 원하지 않는 File이나 directory 있다면 이를 지정할 수 있다.

        ${FILES} :: /bin/time --> transfered time을 파악하여 notify sms@sun; Mail로 알려줌.

5. 이 상태에서 '# rdist -f distfile' 을 수행하면 바로 원하는 File이 description file에 정해진 대로 전송된다. 이 명령어를 수행하면 다음의 예와 같은 내용이 화면에 출력된다.

tech /tmp> rdist -f distfile

updating host sun

/tmp: Warning: remote mode 1777 != local mode 755

installing: /user1/sms/eng/read
installing: /user1/sms/eng/read/1.txt
installing: /user1/sms/eng/read/2.txt
installing: /user1/sms/eng/read/3.txt
installing: /user1/sms/eng/read/4.txt
installing: /user1/sms/eng/read/5.txt
installing: /user1/sms/eng/read/6.txt
installing: /user1/sms/eng/read/7.txt
installing: /user1/sms/eng/read/ab1.txt
installing: /user1/sms/eng/read/ab2.txt
installing: /user1/sms/eng/read/ab3.txt
installing: /user1/sms/eng/read/ab4.txt
installing: /user1/sms/eng/read/ab5.txt
installing: /user1/sms/eng/toeic
installing: /user1/sms/eng/toeic/f1
installing: /user1/sms/eng/toeic/f2
installing: /user1/sms/eng/toeic/f3
installing: /user1/sms/eng/toeic/f4
installing: /user1/sms/eng/toeic/f5
installing: /user1/sms/eng/toeic/f6
installing: /user1/sms/eng/toeic/e1
installing: /user1/sms/eng/toeic/e2
installing: /user1/sms/eng/toeic/e3
installing: /user1/sms/eng/toeic/e4

notify ( sms@sun )

 정해진 시간에 전송하려면 결국 crontab을 사용하여야 한다.

 /var/spool/cron/crontabs 밑에 사용자 별로 있는 File을 문법에 맞게 setting한다. 다음 예는 화요일 14시 16분에 이 명령어를 수행하라는 예이다.

        16 14 * * 2  /bin/rdist -f /user1/sms/distfile

6. 일단 crontabs에 등록, cron daemon kill, /etc/cron.d/FIFO delete, /usr/sbin/cron 수행 하고 나면 변경된 crontabs 내용이 실행된다.                                        

7. 주의할 것은 source file의 permission과 destination directory의 permission. 만일 source는 root permission인데, destination directory가 일반 사용자 permission이라면 명령어 수행도중 permission error 생길 수 있다.

23.5 Prompt변경(HostName & CurrentPath Display)

1) korn shell인 경우

(1) dir function 만들기

 dir()

 {

     cd $1
     PS1="<'uname -n'><'pwd'>

  }

(2) alias시키기

 alias cd=dir

2) C Shell인 경우

alias cd 'cd \!*;set prompt="`hostname`:`pwd`>"'

or

- alias  setprompt  'set prompt="[`hostname`:$cwd]# "'
- alias  cd         'cd \!*; setprompt'
- setprompt

23.6 임시 Host_name 변경

# hostname sun;source /.cshrc

임시로 Host명이 sun으로 바뀌고, /etc/nodename도 sun으로 바뀌고, prompt에 나타난 host_name도 sun으로 바꾼다.

23.7 /file system 100% 일 경우 유용한 command.

/tmp: If several large files are here, reboot and they will be cleaned out.
/dev: Large files may appear here when trying to write to a device andusing the incorrect device name (i.e. /dev/rsto instead of /dev/rst0)
/:   Look for core files
/var: If var is part of the root partition, check for large administration files in /var/adm. Also, some spool files may be left in the /var/spool directories.

    Check for other large files (over 1mb) with the command:
    find / -size +1000000c -xdev -print

tape 작업 시 누군가 /dev/rst0 를 주었음. 2.x 에서는 /dev/rst0 가 존재하지 않음. 따라서 이것이 약 9 M 정도의 file 이 되어 system full이 됨.

23.8 man page에 관한 몇 가지

man은 Solaris의 명령어의 문법과 자세한 설명을 볼 수 있는 일종의 manual이다. 이러한 man을 통하여 명령어의 적절한 사용법과 예제, 관련된 다른 명령어까지도 참조 할 수 있다.

이러한 man을 사용하다 겪는 몇 가지 문제점과 man을 더욱 잘 사용하기 위해 만들어지는 windex에 대해서 몇 가지를 간단히 정리해보려 한다.

1. Solaris install후에 man page만 따로 install하는 경우

    volume manager는 SUNWman package에 있다. 따라서 O/S CD를 먼저 mount 시킨 후에 pkgadd시킨다. 만일 Solaris 2.4에서 cdrom이 /cdrom/cdrom0에 mount되어있다면 다음과 같이 하면 된다.

    # cd /cdrom/cdrom0
    # cd Solaris_2.4
    # pkgadd -d . SUNWman

2. "XXXX에 대한 Manual 항목이 없음." Error

MANPATH에 manual page가 setting 되어있음에도 불구하고 'man 명령어'하면 이와 같은 오류 Message를 띄우면서 실행이 되지 않는 경우가 종종 있다. 이러한 경우에는 windex file에 대한 오류를 생각해 볼 수 있다.

/windex file은 man page의 검색 속도를 높여주는데 사용된다. 만일 windex file이 존재하지만 찾고자 하는 entry가 빠져 있거나 하면 위와 같은 오류 Message를 내면서 manual을 찾는데 실패한다. 각각의 MANPATH에 windex file이 있을 수도 있다. windex file은 다음의 몇 가지 이유로 corrupt 되어질 수 있다.

1) windex size = 0
 : 이 경우에는 이 windex file을 지워주거나, man page를 더하기 위해

2) windex file에 몇가지 man page가 누락되었다.
 : windex file이 만들어진 후에 man page가 추가되는 경우도 많다. catman -w를 실행하여 File을 다시 만든다.

3) windex entry들이 alphabetical order를 따르지 않는다.
 : 수동으로 (by hand)로 editing한 경우에 발생. windex file을 sort하거나 catman -w를 실행한다.

4) windex file의 시작 부분에 additional characters가 있을 때 이러한 문제가 생길 수 있다. 일반적으로 troff나 nroff characters가 삽입되어 있는 경우가 많다.

 : 예제>

잘된 예  ==> ypbind         ypbind(1m)       -NIS binder process
잘못된 예 ==> /f4ypbind      ypbind(1m)       -NIS binder process

3. "sh: less not found" error가 나오는 경우

/usr/ucb/man command가 내는 error:

     Reformatting page. Wait...done
     sh: less: not found

man command는 man page를 화면에 맞추기 위해 reformat을 하게 되는데 이때 nroff를 부른다. 또한 연이어서 nroff에서 나오는 output이 more command와 연계 된다.

하지만 만일 PAGER라는 환경변수가 "less:로 setting되어 있다면 이와 같은 오류가 생길 수 있다.

"less" command는 Sun에서는 지원되지 않는 것으로 more command와 비슷한 command이다. 만일 System이 less command 찾기를 실패하면 man command 또한 오류를 일으킨다.

1) less command가 상주하고 있는 directory를 PATH 변수에 설정해준다.
2) PAGER변수를 "more"로 setting해주거나, " unsetenv PAGER "로 변수를 제거해준다.

4. " nroff: 임시 File을 생성할 수 없음. " error가 나오는 경우 (reformatting page. wait...nroff: cannot create temp file sh: /dev/null: cannot create)
이러한 경우 /var/tmp의 permission이 1777인지 확인한다. 정상적인 경우는 다음과 같이 보인다.

     drwxrwxrwt   2 sys     sys       1536 11월 29일 16:47 tmp

이 permission이 맞지 않으면 일반 사용자 Mode에서 man 사용시 이런 오류가 발생한다. SunOS5.x의 nroff는 임시 File을 쓰기 위해 /var/tmp를 사용한다. 하지만, SunOS 5.1과 SunOS 5.2는 /var/tmp가 아니라 var/tmp가 아니라 /tmp를 사용한다. SunOS 4.x에서도 /tmp 의 permission을 확인해야 한다.

5. man page를 간단히 Print 할 수 있는 방법

man에 -t option을 사용한다. -t option은 default printer상에 manual page를 reformat하고 display하는데 사용된다. 다음의 세가지 환경 변수가 output을 customizing하는데 사용된다.

PRINTER : to set a new default printer
TROFF  : to change the format utility, Usually changed to nroff on non-newsprint printers.
TCAT   : the display program. Defaults to lpr -t

23.9 Login User중 idle time check하여 자동 kill(script)

내용은 host 로 Login한 User중 Idle time이 10분 이상 초과한 User를 자동으로 Kill하는 Procedure 한 것이다.

# SunOS 4.1.3

finger | grep -v root | grep -v oracle |grep svc | cut -c32-38 > /tmp/_list
cat /tmp/_list |cut -c1-2 > /tmp/col1;cat /tmp/_list |cut -c3-7 > /tmp/col2
_tab=`paste -d" " /tmp/col2 /tmp/col1 |\
grep -v "     " |grep -v "   [1-9]"|cut -c7-8`

for i in $_tab

do
/etc/fuser -k /dev/tty$i

done

# Solaris 2.5

finger | grep -v root |grep -v oracle |grep svc | cut -c32-47 > /tmp/_list
cat /tmp/_list | cut -c1-7 > /tmp/col1;cat /tmp/_list | cut -c8-16 > /tmp/col2
_tab=`paste -d" " /tmp/col2 /tmp/col1 |\

grep -v "         " |grep -v "       [1-9]"| cut -c11-17`

for i in $_tab

do
fuser -k /dev/$i

done

이상의 Script를 crontab에 등록하여 1분 간격으로 돌려준다.

23.10 login 보안 및 audit관련 Tip

/etc/default/login 변수...

- CONSOLE 변수는 root로 login 가능한 device지정

예제)

Workstation의 Console을 지정하는 경우 또는 배제

CONSOLE=/dev/console
#CONSOLE=/dev/console

Console에서조차 login 불능

CONSOLE=/dev/null

- PASSREQ=YES (PASSWD를 꼭 필요로 함, default NO)

예제)

MAXWEEKS=15 /* 15주 이상이면 유효기간 만료 */
MINWEEKS=3 /* 최소한 3주는 사용하여야 함 */
PASSLENGTH=6 /* Passwd의 최대의 길이 */
INACTIVE=30 /* 30주 이상 안 쓰면 account locking */
EXPIRATE_DATE=1997.12.31 /* Passwd 소멸일자 */

- SYSLOG=YES ( root login 및 fail에 대한 audit자료 수집 허용여부 ,

audit는 /etc/syslog.conf에 지정된 file에 저장된다. )

/etc/default/passwd file은 default로 password aging관련 File이다.
/etc/default/su file은 SULOG=/var/adm/sulog등으로 log File을 지정할 수 있다.

- /etc/ftpuser file에 등록된 host들은 ftp service 불허
- ftp auditing setting

www% vi /etc/inetd.conf   /* 수정 */

...

#ftp    stream tcp    nowait root   /usr/local/etc/ftpd    ftpd

ftp   stream tcp    nowait root   /usr/sbin/in.ftpd      in.ftpd -l

...

www% vi /etc/syslog.conf

...

daemon.info    ifdef(`LOGHOST', /var/adm/ftp.log, @loghost)

...

syslogd daemon restart

- /var/adm/loginlog file을 만들어 놓으면 5번의 login log fail를 기록할 수 있게 된다.
- /etc/nologin file을 생성하면 모든 사용자 login을 불가능하게 한다.

물론 root user를 제외한다. 그러므로 더 이상의 login을 허용하고자 하지 않을 때 사용한다. nologin file은 rebooting할 때 없어지므로 manual하게 만들든지 또는 crontab에 등록할 수 있다.

- logins -d ( 중복된 user check )
- logins -p ( null passwd user check )

23.11 System에 유저 접근 거부 시킬 때

System 점검 등에 유용할 것이다. 일반 계정의 User는 접근이 거부되고, Super User는 접속 가능하다.

# touch /etc/nologin
# vi... 왜 접근을 거부하는지 에 대한 내용을 포함 시킨다.
# cat /etc/nologin

The system is down right now for routine maintenancee and should be back inline by 23:00. Please check back at this time. Thank you for your understanding, the SYSTEM Admins

23.12 RAID Level

각 RAID 별 장단점

구 분

장 점

단 점

RAID 0

Large Volumes or Drivers

No Fault Tolerance

No Data 보전

RAID 1

(Enhanced)

Large Volumes or Drivers(n/2)성능

Fault Tolerance (n-1)

Data 보전

Extra lost (n/2)성능 (전체)

용량의 감소 (1/2)

RAID 5

Large Volumes or Drivers (n-1)성능

Fault Tolerance (n-1)

Data 보전

Extra lost (n-1)성능

(Overhead)

용량의 감소 (n-1)


RAID 란?

. RAID (Redundant Array of Independent Disks) 개요

- 1987년 버클리 대학에서 여러 개의 Disk를 사용함에 있어서 용량, 성능, 가격, 안전성 등을 감안하여 Disk를 사용하는 방안으로 발전된 표준 규격으로 8개의 RAID Level이 있으나 주로 RAID 0~5까지 사용한다.
- 그러나 RAID 5라고 해서 RAID 1 혹은 RAID 4가 RAID 3에 비해 항상 더 우수한 것은 아니다.

. RAID 1 (Transparent Mirroring)

- 두 개의 다른 Disk에 동시에 Data를 Write 함.
- Single drive보다 빠른 성능을 제공한다.
- Cost에 있어서 두 배의 비용이 필요하다.
- Disk Mirroring은 1개의 Controller에 두 개의 Disk가 연결되며 Duplexing은 각각의 Controller를 갖고 독립적으로 동작한다.

. Enhanced RAID 1

- Mirroring와 Data Striping가 결합된 방식으로 두 가지 Data가 모든 Disk에 교차하면서 저장된다.
- Disk의 수가 홀수가 Mirroring.
- 모든 LG-IBM RAID Adapter 에서 이용이 가능함.
- 두 개의 Disk를 사용하는 것에 비해 성능 및 Flexibility 하게 Disk를 사용할 수 있다.

. RAID 0 (Striping)

- Data 가 모든 Drive에 짝수로 교차하여 분포됨.
- 중복이나 Error Correction 이 되지 않음.
- 동시에 수행되는 도구에 대해 빠른 성능을 발휘함.
- 특히 큰 Size 의 File을 Access 할 때 성능이 좋다.
- 하나의 Disk가 Fail 일 경우 전체적인 System 이 중단된다.

. RAID 5 (Data Striping With Skewed Parity)

- Data와 Checksun 이 Drive에 균일하게 펼쳐짐.
- Random한 처리에 우수한 성능.
- Drive는 독자적으로 운영 (Sync가 불필요)
- RAID 2,3,4에 비해 더 높은 성능을 나타냄.
- 1개의 Drive 용량의 Cost가 낮아 경제적임.
- Disk의 수가 3개 이상으로 구성되며 같은 용량으로 구성될 경우에 최적의 구성이 사용 가능 용량은 N-1 이 된다.

23.13 System의 재설정 (Host_name 및 Network 정보)

   # sys-unconfig  

          ; host-name , IP-Address , Network 관련하여 OS Install과 무관하게 재 설정할 수 있다. System을 운용하다. 필요에 의해 Host 정보를 System Default 상태로 바꾸기 위해 사용된다.

   sys-unconfig performs the following tasks:

       1. Restore the default /etc/inet/hosts files.
       2. Removes the default host name in /etc/hostname.??[0-9] and /etc/nodename.
       3. Removes the default domain name in /etc/defaultdomain.
       4. Restores the time zone to PST8PDT in /etc/TIMEZONE.
       5. Disables the Network Information Service(NIS) and Network Information Service Plus (NIS+) if either NIS or NIS+ was configured.
       6. Removes the entries for this host in /etc/net/*/hosts.
       7. Removes the file /etc/inet/netmasks.
       8. Removes the password set for root in /etc/shadow.

   Host-name만 변경

       /etc의 nodename,hosts,hostname.???(??? is Net_Interface=le0 or hme0)을 변경.
       이 경우 Host_name을 참조 하는 licensed S/W 가 있다면, 이것도 바꿀 것.

23.14 NETWORK상에서 C-COMPILE하는 방법

*** COMPILE LICENSE가 1 user일 때 NETWORK를 통해서 COMPILE 하는 방법임. ***

1. 먼저 각 SYSTEM에 COMPILE S/W, LICENSE S/W를 설치한다.
2. LICENSE SERVER 에 LICENSE PASSWORD를 입력한다.
3. LICENSE SERVER SYSTEM

# setenv LM_LICENSE_FILE /opt/SUNWspro/license_dir/sunpro.lic,1:$LM_LICENSE_FILE      ( .cshrc 에 첨가함)

4. NETWORK 상에 연결된 SYSTEM 가)

# setenv LM_LICENSE_FILE port@hostname --> hostname은 license server system name ( .cshrc 에 첨가함)
  (ex. # setenv LM_LICENSE_FILE 7558@axil)

나) # setenv LD_LIBRARY_PATH $OPENWINHOMW/lib:/usr/lib ( .cshrc에 첨가함)

** Solaris 2.x 일 경우 /etc/opt/licenses/licenses_combined 에서 port number를 확인.
** Network 에 연결된 system 를 license demo 구동 or system rebooting 함

23.15 Solstice Compiler Install

Install과정

1. CD에서 lit(License Installation Tools) 파일로 인스톨 (CD에 lit파일이 존재함.)

   cd#spro-install-tool

   1)좌측상단의 Install 하고자 하는 Product를 선택
   2)License Install 란에 check-sign을 하고, 상단 중앙부의 Install 버튼을 click한다.

     *SPARCworks 같은 경우, 아래의 3가지 모두 한번에 설치 됨.

        - SPARCworks Common Tools
        - SPARCworks
        - SPARCompiler

2. License 양식 작성해서 FAX 보낸 후 License가 도착하면 Install 진행
3. /etc/opt/licenses/lit 실행
4. 예) C 4.0 Install 시

      1) Sparc Compiler C, 4.0부터 Install RTU(Right To Use: User 수) , PASSWORD 입력

         * PC(Password Checksum), DC(Data Checksum)을 확인, 여기서 PC는 License의 것과 반드시 일치하는지 확인.

      2) Sparcworks 3.1 , Common Tools , exit 순으로 진행
      3) /etc/opt/licenses/LIC_CONFIG_SCRIPT 실행

5. vi /.cshrc 편집 (path에 추가)

      set path=(/bin /usr/bin /usr/sbin /usr/ucb /etc /opt/SUNWspro/bin /usr/openwin/bin .)
      setenv OPENWINHOME /usr/openwin
      setenv LD_LIBLARY_PATH /opt/SUNWspro/lib:/usr/lib
      setenv MANPATH /usr/man:/opt/SUNWspro/man

       * 위 내용처럼 path, lib, man 추가설정

23.16 System 초기 설치 시 참고

* System 설치 후(& User 등록 시) 초기 Configure File 들의 위치

; User 등록 시에 skel DIR을 지정해 주면, 자동으로 User의 Home Directory에 아래 초기 설정 File이 copy된다.

[/etc/skel/] : 2.x

  local.cshrc, local.login, local.profile

- 일반 User들이 사용할 path 라던지, 필요한 부분을 적절히 수정해서 이런 이름으로 넣어 놓으면, User 생성시 자동으로 User의 home에 copy됨.

[/usr/lib/] : 4.1.3

  cshrc , login

4.1.3 OS Install 시 참고. (96.5.25)

ex) 단국대 Axil245 설치(6set)

   Mem 32M, OS 4.1.3 , Compiler (C,C++,fortran,cobol,pascal)

   << HDD 1G >>       

Start Cyl.

Block

UFS

Capacity(M)

0

120960

/

60

120

200592

swap

101

319

900144

/usr

420

1212

830592

/home

380


* Partition 나눌 때 - 70*2000=?cyl : 70(나누고자 하는 M수)에 2000을 곱하면 대략적 값이 나온다.

  위의 계산법으로 Cylinder 수를 계산하여 그 값만 써주고, 다시 설정하여 "?/" 이런 식으로, 짜투리 값을 없앤다. 겹치는 부분이 없게 하기 위해서 다음 cly 수 계산시는 처음부터의 바로 전까지의 cyl수를 모두 합한 값이다

* Host명 및 IP-ADDR 다시 설정할 때

   #sys-unconfig : Host 명 및 IP-ADDR은 알아서 잘 넣고, TimeZone 설정 시는 "ROK"라고 할 것.

* .cshrc File 편하게 setting 하는 법 !

   #cp /usr/lib/Cshrc /.cshrc 하여 .cshrc를 편집.

       2.x일 경우 : #cp /etc/skel/local.cshrc /.cshrc
                    #cp /etc/skel/local.profile /.profile
                    #cp /etc/skel/local.login /.login

23.17 특정 User의 File 실행할 때

- single command 일 때
  #su - oracle -c /home/dir/dir/실행할_file_name

- multi command or argument가 있을 때
#su - oracle -c '/home/dir/dir/실행할 File|다른명령|다른명령'

23.18 Remote Utility 실행

X환경의 Application을 Client에서 실행하게 한다.

#xhost +           <-- 모든 Client에 대해서 접근을 허가한다.
#telnet sun

...login....

#xhost +
#setenv DISPLAY 현host_name:0
#netscape &

저작자 표시 비영리 변경 금지
Creative Commons License
Posted by BLUEDAY™