LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   EMAC tut. (https://www.linuxquestions.org/questions/linux-general-1/emac-tut-515647/)

>>BLACKHOLE<< 01-02-2007 12:46 PM

EMAC tut.
 
Hey whats up fellow members-
---------------------------

I'm stuck on a small issue about creating files. Im trying to fully understand the emac editor, but when it comes to making, creating and editing files, I don't fully understand it. The help menu explains things kind of confusing.

Does anybody have a tut that explains in detail how to make files in emac, because I've been searching the net and can't seem to locate any.
________________________________________________________

Another question:

My server has no gui and I wanted to create a virtual file for my interface, which looks like this:


/etc/sysconfig/network-scripts/ifcfg-ra0

DEVICE=ra0
BOOTPROTO=dchp
IPADDR=192.168.0.100
NETMASK=255.255.255.0
NETWORK=192.168.0.0
BROADCAST=192.168.0.255
ONBOOT=yes
METRIC=10
MII_NOT_SUPPORTED=no
USERCTL=no
IPV6INIT=no
IPV6TO4INIT=no
PEERDNS=yes
NETMASK=255.255.255.0
IPADDR=192.168.100


I want to make it like this:

/etc/sysconfig/network-scripts/ifcfg-ra0:0

DEVICE=ra0:0
BOOTPROTO=dchp
IPADDR=192.168.0.101
NETMASK=255.255.255.0
NETWORK=192.168.0.0
BROADCAST=192.168.0.255
ONBOOT=yes
METRIC=10
MII_NOT_SUPPORTED=no
USERCTL=no


then restart my network.

If I can't make files and edit files I can't do anything else :mad:

All help is appreciated!!!
______________________________________________________
>>BLACKHOLE<<

>>BLACKHOLE<<

2007-(-_+)

billymayday 01-02-2007 01:37 PM

Have you seen this?

http://www.gnu.org/software/emacs/manual/index.html

You can use other editors you know. If you don't like emacs, try something like vim. If you do try vim, this may help

http://www.tuxfiles.org/linuxhelp/vimcheat.html

uselpa 01-02-2007 02:01 PM

Blackhole, when asking 2 completely unrelated questions, you should really create 2 threads, each one in the correct subforum. That will help you get better answers.

>>BLACKHOLE<< 01-02-2007 09:51 PM

Thanks for the replys-
---------------------

Sorry for posting in the wrong forum. Sometimes I get confused on which question would fit which forum. Thanks for the advice.
________________
>>BLACKHOLE<<

>>BLACKHOLE<<

2007-(-_+)

>>BLACKHOLE<< 01-04-2007 10:37 PM

hey guys-
--------

GOAL:

I'm trying to create the file:

/etc/sysconfig/network-scripts/ifcfg-ra0:0
DEVICE=ra0:0
BOOTPROTO=dhcp
IPADDR=192.168.0.101
NETMASK=255.255.255.0
NETWORK=192.168.0.0
BROADCAST=192.168.0.255
ONBOOT=yes
METRIC=10
MII_NOT_SUPPORTED=no
USERCTL=no
WIRELESS_MODE=managed
WIRELESS_ESSID=My Network
WIRELESS_ENC_KEY="restricted xxxxxxxxxxxxxxxxxxxxxxxxxx"
DHCP_CLIENT=dhclient


I open a buffer in emac via the command C-x C-f and key in the above code, but when I save it with the command C-x C-s
The bottom of the screen says:

/home/my-login/etc/sysconfig/network-scripts/ifcfg-ra0:0: no such directory
_____________________________________________________

I want this file as the virtual interface

Does anyone know the code to fix this problem???
THANKS in advanced for any help!

________________
>>BLACKHOLE<<

>>BLACKHOLE<<
2007-(-_+)

kotnik 01-05-2007 12:01 AM

Emacs say that becose there's no network-scripts directory. Use "M-x make-directory" within emacs, or type this in your terminal:

mkdir -p /home/my-login/etc/sysconfig/network-scripts/

billymayday 01-05-2007 12:58 AM

Are you sure? looks more like it's simply appending the directory structure to /home/%user

Try saving to absolure - ie /etc not etc

>>BLACKHOLE<< 01-05-2007 01:21 PM

Thanks guys, Im gonna try both to see which one might work.

kotnik 01-05-2007 06:34 PM

billymayday is right. State absolute path, not relative (absolute starts with /).


All times are GMT -5. The time now is 03:41 AM.