How do I edit a read only file in Ubuntu?

Duyên Trương

New member
How do I edit a read only file in Ubuntu?
Answer
Long Answer
  1. Log in as the root user:
    [email protected]
    :~$ sudo su –
  2. Open hostname:
    [email protected]
    :~# vi /etc/hostname.
  3. You will see oldName . …
  4. Open hosts:
    [email protected]
    :~# vi /etc/hosts. …
  5. Similarly to what you did in step 3, change the computer name from oldName to newName . …
  6. Exit the root user:
    [email protected]
    :~# exit.
 

Tìm kiếm

Back
Top