Can't login with admin after reinstall

Tim

Verified User
Joined
Oct 8, 2003
Messages
117
I reinstalled DirectAdmin (FreeBSD 4.9) because of a lot of troubles

but now i get the next error:

2004:02:24-22:01:24: Unable to write session file:
2004:02:24-22:01:24: Unable to read ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>

2004:02:24-22:01:24: Unable to write ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>
Unable to get Lock on file<br>

how can i fix this?

It seems to be a permission problem, so i did:

./directadmin p

But that didn't help.

Then i removed everything of directadmin, still nothing
 
Hello,

Unable to write session file:

means that /home/tmp isn't writeable.

mkdir /home/tmp
chmod 1777 /home/tmp

John
 
DirectAdmin Support said:
Hello,

Unable to write session file:

means that /home/tmp isn't writeable.

mkdir /home/tmp
chmod 1777 /home/tmp

John
2004:02:25-23:26:16: Unable to write session file:
2004:02:25-23:26:16: Unable to read ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>

2004:02:25-23:26:16: Unable to write ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>
Unable to get Lock on file<br>

still the same error, i'm sorry
 
Hello,

Things that are needed for a login:

- /home/tmp must be chmod 1777
- /usr/local/directadmin/data/users/username/user.conf must exist and have the usertype set.
- the users password must be setup in /etc/passwd and be working.

But the "Unable to write session file" error means that /home/tmp isn't writeable by "diradmin" ..so double check that the directory is chmod'ed to 1777 ... not sure anythinge else could prevent the file from being written.

John
 
DirectAdmin Support said:
Hello,

Things that are needed for a login:

- /home/tmp must be chmod 1777
- /usr/local/directadmin/data/users/username/user.conf must exist and have the usertype set.
- the users password must be setup in /etc/passwd and be working.

But the "Unable to write session file" error means that /home/tmp isn't writeable by "diradmin" ..so double check that the directory is chmod'ed to 1777 ... not sure anythinge else could prevent the file from being written.

John

/home/tmp
lrwxrwxrwx 1 root wheel 9 Jan 27 16:52 /home -> /usr/home

correct

/usr/local/directadmin/data/users/
is just empty

su-2.05b# cd /usr/local/directadmin/data/users
su-2.05b# ls -la
total 4
drwx--x--x 2 diradmin diradmin 512 Feb 24 22:29 .
drwx--x--x 7 diradmin diradmin 512 Feb 26 18:02 ..

Problem found i think ..

passwd file:
admin:*:1007:1007:User &:/home/admin:/bin/sh

correct
 
Hello,

Code:
cd /usr/local/directadmin/data/users
mkdir admin
chown diradmin:diradmin admin
chmod 711 admin
cd /usr/local/directadmin
./directadmin i
John
 
DirectAdmin Support said:
Hello,

Code:
cd /usr/local/directadmin/data/users
mkdir admin
chown diradmin:diradmin admin
chmod 711 admin
cd /usr/local/directadmin
./directadmin i
John

almost i think :)

Code:
2004:02:26-19:13:11: Unable to create ~/.shadow in
2004:02:26-19:13:24: Unable to write session file:
2004:02:26-19:13:24: Unable to read ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>

2004:02:26-19:13:24: Unable to write ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>
Unable to get Lock on file<br>
 
DirectAdmin Support said:
Hello,

Code:
cd /usr/local/directadmin/data/users
mkdir admin
chown diradmin:diradmin admin
chmod 711 admin
cd /usr/local/directadmin
./directadmin i
John


I ran into the exact same problem and the steps above worked. Of course the original issue I set out to do the reinstall for still isn't working but at least I can login as Admin again.
 
i still get:

Invalid login. Please verify your Username and Password

and the same lock / login.hist error :(
 
Hello,

If you actually get an error message, that means you probably have an incorrect password. Check the /usr/local/directadmin/scripts/setup.txt to get the adminpass

John
 
i allready did that, and it was the same password

Code:
[b]2004:02:27-18:33:43: Unable to write session file:[/b]
2004:02:27-18:33:43: Unable to read ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>

2004:02:27-18:33:43: Unable to write ./data/admin/login.hist: Can't get a lock on ./data/admin/login.hist<br>
Unable to get Lock on file<br>

i still get the same error....

the bold error is new since i did what you said
 
Have you checked all the settings in this thread?

/home/tmp is 1777
/usr/local/directadmin/data/users/admin/user.conf exists and has usertype=admin in it.
The admin password is correct (try sshing into admin)

Failing all that, just send us your ip and root password to [email protected]

John
 
if you read the whole topic you can see that i've done everyting

i've send a e-mail
 
Hello,

I forget if it was you, but I recieved an email with that problem, and a simple "killall -9 directadmin" and a restart of DA was all that was required.

John
 
Back
Top