# help need in adding a daily user login

## adamz

hello.. i added a user login to be used instead of using root...but i have trouble accessing the internet when i am logged in to my daily user name account.. instead if i use root.. i can easily have access to the net... i am using an aztech ADSL 100U modem so i connect to the net using eci-adsl... do help.. im in need of help...

----------

## NeddySeagoon

adamz,

Do not use root to browse the net - its like using Windows without a firewall, virus checker, spam blocker, defrag tool, ad blocker etc.

Since it works for root but not for your ordinary user, its likely to be a permissions problem.

What protocol do you use from your computer to the net?

It may be that your ordinary user is not allowed to start and stop this protocol. If you don't know, connect to the internet, run /sbin/ifconfig and post the results.

How is your PC connected to the 'modem'?

----------

## adamz

hello there..

# /sbin/ifconfig

lo        Link encap:Local Loopback

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:4718 errors:0 dropped:0 overruns:0 frame:0

          TX packets:4718 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:243444 (237.7 Kb)  TX bytes:243444 (237.7 Kb)

ppp0      Link encap:Point-to-Point Protocol

          inet addr:219.95.222.10  P-t-P:219.93.218.177  Mask:255.255.255.255

          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1

          RX packets:24480 errors:0 dropped:0 overruns:0 frame:0

          TX packets:18597 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:3

          RX bytes:32780539 (31.2 Mb)  TX bytes:1958684 (1.8 Mb)

this is what i get after running /sbin/ifconfig

my connection is connected using eci-adsl driver...

hope to hear from u soon..

----------

## vonhelmet

Is there some script in /etc/init.d that should be getting run during startup to get your modem going?

----------

## adamz

nope.. none that was suppose to be run from it to get the modem running.. the modem is already on...only i cant get myself online from the user account i created...

----------

## NeddySeagoon

adamz,

You use Point To Point protocol (PPP) to connect too the net. Normally only root can start and stop it.

You should start your internet connection at boot time with a script (run it by doing an rc-update add <script> default.

Root will then start PPP for you and any user can use the connection when its up.

I don't know how to use eci-adsl so can't advise further.

How do you start your internet connection as root now?

----------

## adamz

hello NeddySeagoon,

what script should i use in this case? i totally know nothing..

i start my internet connection everytime by loggin into root and by simply use terminal and type "startmodem" to get my adsl connected to the net...then usually i log off from root and enter my other user login to use the net and so on..

----------

## NeddySeagoon

adamz,

First, look in /etc/init.d to see if startmodem is there. If it is,

do

```
rc-update add startmodem default
```

.

If /etc/init.d/startmodem does not exist, edit /etc/conf.d/local.start and add at the end of the file a line that says 

```
startmodem
```

.

The file /etc/conf.d/local.start is for adding commands you want to run at startup. Its twin, /etc/conf.d/local.stop is fo commands you want to run at shutdown.

----------

## adamz

hello NeddySeagoon,

i searched in /etc/init.d and i couldnt find startmodem there..and also i tried editing /etc/conf.d/local.start and i reboot and it says something like " fail to run local" 

so im lost....

is there any alternative way to do this? like setting the right permissions for my user? if there is how do i do it?

----------

## NeddySeagoon

adamz,

Check the spelling and capitalisation of startmodem in /etc/conf.d/local.start.

You can fix it by changing permissions, as you suggest but I'm not a PPP user so I don't know where.

----------

## adamz

hello NeddySeagoon,

ive checked the spelling and capitalisation of startmodem...its in the right order.. everything is correct only it doesnt run..   :Sad: 

what do u think i should do?

----------

## adamz

hello...

ive tried searching for the script and i found it.. i added it in /etc/init.d/ 

the file is called rc.adsl

i added it using

rc-update add rc.adsl default

and it didnt work....

so instead i tried  editing /etc/conf.d/local.start and put rc.adsl

and still it doesnt work..

im very lost here.. could any one please tell me what should i do now?[/code]

----------

## adamz

i actually got my connection working on boot

but the problem is i still cant get my user account to connect to the net..

but i still can use the net when i use root....

does anyone know how to change the permission of my user account have access to the net?

please help....

----------

## Jakub

Hmm, maybe it's the wrong permissions on /etc/resolv.conf? Try that, and if it works than add that chmod 0644 line to /etc/ppp/ip-up:

```

...

        # backup the old configuration and install the new one

        cp -a $REALRESOLVCONF    $REALRESOLVCONF.pppd-backup

        mv $REALRESOLVCONF.tmp $REALRESOLVCONF

        chmod 0644 $REALRESOLVCONF

        fi

...

```

----------

