Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 02-11-2011, 11:39 AM   #1
Registered: Mar 2009
Location: Virginia, US
Distribution: Ubuntu 10.10 & Debian 6.0.3,
Posts: 348

Rep: Reputation: 7
Help me backup a configuration file?

I've read:

It's always a good idea to backup a configuration file like sources.list before you edit it. To do so, issue the following command: sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup

Where does it backup to and how do I access it? I want to put the backup on removable disk or upload it
Old 02-11-2011, 11:47 AM   #2
Senior Member
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 344Reputation: 344Reputation: 344Reputation: 344
The format of the cp (copy) command is:

cp <source> <destination>

So in your example, you are copying the file '/etc/apt/sources.list' to the file '/etc/apt/sources.list.backup'.

Your backup is in '/etc/apt/sources.list.backup', which you can copy elsewhere if you like.
Old 02-11-2011, 11:50 AM   #3
LQ 5k Club
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,529

Rep: Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899Reputation: 899
cp /etc/apt/sources.list /etc/apt/sources.list.backup
It's backup to the
To make a backup to a removable disk,
mount the disk and use
cp /etc/apt/sources.list /PATH/TO/THE/DISK/sources.list.backup
To upload the file, point your ftp to the
directory, or where ever you stored the file

Kind regards


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
CPIO backup / configuration exactiv Linux - Software 3 05-25-2009 09:51 AM
Error when attempting backup with File Backup lglrgl Linux - Software 0 08-03-2006 10:38 AM
backup configuration file for webmin via command line? paul_mat Linux - Networking 1 02-05-2006 01:54 PM
Backup XFree86 configuration C.Loko Slackware 2 10-31-2003 04:05 AM
backup and update the backup file doris Linux - General 4 08-24-2002 07:26 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:40 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration