Operating System - HP-UX
1833703 Members
3342 Online
110062 Solutions
New Discussion

Create /var/adm/btmp file !!

 
SOLVED
Go to solution
Whitehorse_1
Frequent Advisor

Create /var/adm/btmp file !!

Hi,

I understood the imporatnce of "btmp" file on security standpoint. One of my system has no "btmp" file. How can I get it back, or create new "btmp" data file.

Thxs, WH
Reading is a good course medicine for deep sleep !!
6 REPLIES 6
Jaime Bolanos Rojas.
Honored Contributor

Re: Create /var/adm/btmp file !!

Whitehorse,

You want to use the command
#touch /etc/btmp

remember this file keeps sensitive information so you want to restrict the access to it.

To view the information use the lastb command.

Regards,

Jaime.

Work hard when the need comes out.
Steven E. Protter
Exalted Contributor

Re: Create /var/adm/btmp file !!

Shalom WH,

As root.

touch /var/adm/btmp

That will create it and it should be able to be updated immediately. You may need to restart syslog.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Sp4admin
Trusted Contributor
Solution

Re: Create /var/adm/btmp file !!

hello,

We create the file im /etc/btmp then link it to /var/adm/btmp.

So as Steve said you can touch the files to create it. and check the permmsions.

sp,
James R. Ferguson
Acclaimed Contributor

Re: Create /var/adm/btmp file !!

Hi:

Well, it appears that you posted this about four times. That said:

As root, do:

# touch /var/adm/btmp
# chmod 600 /var/adm/btmp

*Note* that you make the file readable only by 'root'. You don't want users snooping to see the clear-txt bungled login information!

Regards!

...JRF...
Whitehorse_1
Frequent Advisor

Re: Create /var/adm/btmp file !!

Hi Admins, Thxs for all the replies..

Got another Qn:

What needs be done, if /var/adm/inetd.sec file vanishes.

Thxs, WH
Reading is a good course medicine for deep sleep !!
Jaime Bolanos Rojas.
Honored Contributor

Re: Create /var/adm/btmp file !!

Whitehorse,

This explains the situation:

"The file inetd.sec allows the system administrator to control which hosts (or networks in general) are allowed to use the system remotely. This file constitutes an extra layer of security in addition to the normal checks done by the services."

"If file /var/adm/inetd.sec does not exist, security is limited to that implemented by the servers."

For more info, take a look at this doc:

http://docs.hp.com/en/B2355-90696/inetd.sec.4.html

Regards,

Jaime
Work hard when the need comes out.