[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Editing a .conf file in linux

Posted on 2013-10-29
3
Medium Priority
?
559 Views
Last Modified: 2013-10-29
Hi,

I'm trying to edit the following on my NAS but not sure how to open and edit.
/usr/syno/etc/smb.conf

I just get an access denied if I just paste it into putty.
0
Comment
Question by:wannabecraig
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 23

Accepted Solution

by:
savone earned 2000 total points
ID: 39609441
Try using the vi editor.

vi /usr/syno/etc/smb.conf

You might want to read a little about vi, it can be confusing.

http://www.cs.colostate.edu/helpdocs/vi.html
0
 
LVL 7

Expert Comment

by:SterlingMcClung
ID: 39609455
Are you sure you have permission to edit the file?  What user are logging in as?  If you don't have permission and you aren't logged in as the super user, you can try using
sudo

Open in new window

or
sudo su

Open in new window

to gain super user rights.  If you do have the proper permissions, and it is just a matter of which program to use, then it is going to depend on the particular NAS that you are using.  Common file editing programs in Linux include: vi, vim, emacs and nano.  Nano is my favorite, as it has a listing of keyboard shortcuts listed on the screen while you are typing. Many of the other editors, while far superior in capabilities, are very difficult to start using due to odd keystrokes that are required and not well documented on screen.  It has been some time, but I believe all of these can open a file by typenig the executable name followed by the file to edit.  So in your case:
nano /usr/syno/etc/smb.conf

Open in new window

, or
 sudo nano /usr/syno/etc/smb.conf

Open in new window

if you want to run as the super user.

If
0
 
LVL 13

Expert Comment

by:Daniel Helgenberger
ID: 39609457
Also, try nano, a console editor which might be installed on your system; a little bit more straightforward than vi:
nano /usr/syno/etc/smb.conf

Open in new window

If you can connect via ssh, then copy the conf to your local system and edit it with a gui text editor:
scp root@<yourNAShostname>:/usr/syno/etc/smb.conf .

Open in new window

Reverse this to copy it back. On windows, use Putty.
0

Featured Post

Learn how to optimize MySQL for your business need

With the increasing importance of apps & networks in both business & personal interconnections, perfor. has become one of the key metrics of successful communication. This ebook is a hands-on business-case-driven guide to understanding MySQL query parameter tuning & database perf

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question