Page 2 of 2 FirstFirst 12
Results 11 to 15 of 15

Thread: Automatic Network configure in ubuntu server 12.04.1 ?

  1. #11
    Join Date
    Jan 2013
    Beans
    17

    Re: Automatic Network configure in ubuntu server 12.04.1 ?

    I have tried to give the write permission to the interfaces file but it gives me following error
    root@gaurav:~# sudo chmod 644 /etc/network/interfaceschmod: changing permissions of `/etc/network/interfaces': Operation not permitted

    so that i cant change the file because it is still showing read-only

  2. #12
    Join Date
    Apr 2012
    Beans
    6,420

    Re: Automatic Network configure in ubuntu server 12.04.1 ?

    Quote Originally Posted by gauravjain View Post
    root@gaurav:~# sudo chmod 644 /etc/network/interfaceschmod: changing permissions of `/etc/network/interfaces': Operation not permitted
    Are you doing this from the recovery console? if so, the filesystem is likely mounted read-only

    Also, you don't need sudo if you are already root

  3. #13
    Join Date
    Jan 2013
    Beans
    17

    Re: Automatic Network configure in ubuntu server 12.04.1 ?

    No.. No.. I am not doing in recovery mode.. I am doing everything in a main os.
    And I also tried without sudo. But still getting same error.
    I cant understood anything.

  4. #14
    Join Date
    Apr 2012
    Beans
    6,420

    Re: Automatic Network configure in ubuntu server 12.04.1 ?

    OK so maybe you made the file immutable for some reason? you can check with

    Code:
    lsattr /etc/network/interfaces
    If so you will need to use

    Code:
    sudo chattr -i /etc/network/interfaces
    before you can change the mode - but you should understand WHY you made it immutable

    Code:
    $ sudo chmod 600 /etc/network/interfaces
    $ ls -l /etc/network/interfaces 
    -rw------- 1 root root 116 Feb 20 08:35 /etc/network/interfaces
    
    $ sudo chattr +i /etc/network/interfaces
    $ lsattr /etc/network/interfaces 
    ----i--------e- /etc/network/interfaces
    
    $ sudo chmod 644 /etc/network/interfaces
    chmod: changing permissions of `/etc/network/interfaces': Operation not permitted
    $
    $ sudo chattr -i /etc/network/interfaces
    $ sudo chmod 644 /etc/network/interfaces
    $ ls -l /etc/network/interfaces 
    -rw-r--r-- 1 root root 116 Feb 20 08:35 /etc/network/interfaces

  5. #15
    Join Date
    Jan 2013
    Beans
    17

    Re: Automatic Network configure in ubuntu server 12.04.1 ?

    I don't know how to say you thanx... It worked great... and I removed total eth0 from /etc/network/interfaces. Now it takes IP automatically from router. Thank u so much...

Page 2 of 2 FirstFirst 12

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •