새로운 계정을 추가한 후에, 그 사용자가 처음 로긴할 때 비밀번

yangam의 이미지

새로 생성된 계정이 yangam 이라고 하고,
그 사용자가 처음 login 했을 때.....

login: yangam
Choose a new password.
new Password: 
Re-enter new Password:

yangam$ _

학교 서버가 Solaris 인데요..
처음에 사용할 때 그랬거든요.
그래서 제가 사용하고 있는 리눅스 머신에서도
그렇게 하려고 했는데.. 제대로 되지 않더라구요.
여러 가지 자료를 나름대로 찾아봤습니다.
(똑같은 질문하신분도 계시더라구요)

셸 스크립트를 쓰면 된다.
로그인 셸에 /usr/bin/passwd 를 입력하면 된다.. 등등

그런데, 제가 학교 서버를 살펴보니
내용이 다음과 같았습니다.
우선, 계정 ID가 cen04128 입니다.
그리고 /etc/passwd 의 cen04128 과 관련된 내용을 살표보니..

cen04128:x:2870:2001:2004151028_YoonYeoJun:/u4/cestu/04/cen04128:/bin/csh

또한, cen04128 의 계정에는 .cshrc, .profile, .login 화일이 있었습니다.
각 화일이 내용을 또한 보여드리자면...

.cshrc 의 내용

# @(#)cshrc 1.11 89/11/29 SMI
umask 022
set path=(/usr/local/bin /usr/local /bin /usr/bin /usr/ucb /etc .)
if ( $?prompt ) then
        set history=32
endif

.login 의 내용

# @(#)local.login 1.5     98/10/03 SMI
stty -istrip
# setenv TERM `tset -Q -`
                                                                                
#
# if possible, start the windows system.  Give user a chance to bail out
#
if ( "`tty`" == "/dev/console" ) then
                                                                                
        if ( "$TERM" == "sun" || "$TERM" == "sun-color" || "$TERM" == "AT386" )
then
                                                                                
                if ( ${?OPENWINHOME} == 0 ) then
                        setenv OPENWINHOME /usr/openwin
                endif
                                                                                
                echo ""
                echo -n "Starting OpenWindows in 5 seconds (type Control-C to interrupt)"
                sleep 5
                echo ""
                $OPENWINHOME/bin/openwin
                clear           # get rid of annoying cursor rectangle
                logout          # logout after leaving windows system
        
        endif
        
endif

.profile 의 내용

# @(#)local.profile 1.8 99/03/26 SMI
stty istrip
PATH=/usr/bin:/usr/ucb:/etc:.
export PATH
                                                                                
#
# If possible, start the windows system
#
if [ "`tty`" = "/dev/console" ] ; then
        if [ "$TERM" = "sun" -o "$TERM" = "sun-color" -o "$TERM" = "AT386" ]
        then
                                                                                
                if [ ${OPENWINHOME:-""} = "" ] ; then
                        OPENWINHOME=/usr/openwin
                        export OPENWINHOME
                fi
                                                                                
                echo ""
                echo "Starting OpenWindows in 5 seconds (type Control-C to interrupt)"
                sleep 5
                echo ""
                $OPENWINHOME/bin/openwin
                                                                                
                clear           # get rid of annoying cursor rectangle
                exit            # logout after leaving windows system
        
        fi
fi

음.. 별로 중요한 내용은 아닐지 모르겠네요.
다만, 최대한의 정보를 드리고자.....;;;;;;

도데체 어떻게 해야 하나요?

자료를 나름대로 열심히 뒤져봤지만 원하는 내용이 나오지 않네요.
안녕히계세요.

codebank의 이미지

처음 이 질문을 보고 기억이 잘 나지 않아서 고민했었는데 제가 기억하기로는
유저 홈의 그 파일들과는 관련이 없습니다.
즉, login시에 계정과 암호를 물어보고 시스템에서 체크하는 파일은 다른 파일입니다.
그 파일은 /bin/login 파일이 담당하는 걸로 기억합니다.
man을 이용해서 살펴보니 /etc/login.defs라는 파일과 밀접한 연관이 있더군요.
시스템 또는 배포판에 따라서 위치가 틀릴 수도 있으니 일단은 man login으로
해당 파일이 어디에 있는지 확인해 보시는게 좋을겁니다.

------------------------------
좋은 하루 되세요.

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.