LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 07-21-2017, 12:40 AM   #1
horwoodabitibi
LQ Newbie
 
Registered: Sep 2012
Location: Timmins Ontario
Posts: 13

Rep: Reputation: Disabled
How to download a file that I accidently removed?


I am building a "LAMP." After installing Myslq I accidently erased the "index.html" file from /var/www directory. Is it possible to download just that file? I have tried to re-installing myslq-server but I get the message that it is already installed.

Thank you
Don
 
Old 07-21-2017, 12:57 AM   #2
hazel
Senior Member
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 2,878
Blog Entries: 7

Rep: Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501
If you use apt-get with the -d option, it should just download the package. Then you could use dpkg to unpack it and find the file you want.

A simpler procedure would be to remove mysqlq and then install it again.
 
1 members found this post helpful.
Old 07-21-2017, 01:24 AM   #3
Turbocapitalist
Senior Member
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 3,909
Blog Entries: 3

Rep: Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858Reputation: 1858
That file is probably from the Apache2 package. You can be sure by checking:

Code:
dpkg -S /var/www/index.html
Then once you know the name of the package it came from, maybe the easy way is to reinstall it.

Code:
apt-get --reinstall install apache2
However, that specific file is not so important. You can make your own and it would be just as valid.
 
1 members found this post helpful.
Old 07-21-2017, 06:29 AM   #4
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 3,622

Rep: Reputation: 105Reputation: 105
Here is the default file.

Code:
cat /var/www/index.html
<html><body><h1>It works!</h1>
<p>This is the default web page for this server.</p>
<p>The web server software is running but no content has been added, yet.</p>
</body></html>
The default permissions of the file.

Code:
ls -l /var/www/index.html
-rw-r--r-- 1 root root 177 Nov 22  2016 /var/www/index.html
 
1 members found this post helpful.
Old 07-21-2017, 11:45 AM   #5
horwoodabitibi
LQ Newbie
 
Registered: Sep 2012
Location: Timmins Ontario
Posts: 13

Original Poster
Rep: Reputation: Disabled
Lightbulb

Quote:
Originally Posted by horwoodabitibi View Post
I am building a "LAMP." After installing Myslq I accidently erased the "index.html" file from /var/www directory. Is it possible to download just that file? I have tried to re-installing myslq-server but I get the message that it is already installed.

Thank you
Don
Thank you for your help. My little problem is resolved!
Don
 
Old 07-21-2017, 11:55 AM   #6
hazel
Senior Member
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 2,878
Blog Entries: 7

Rep: Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501
Quote:
Originally Posted by horwoodabitibi View Post
Thank you for your help. My little problem is resolved!
Don
Mark it as solved then.
 
1 members found this post helpful.
  


Reply


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
Removed accidently removed panel at Suse 11.1? alte_mann SUSE / openSUSE 6 01-29-2009 04:19 AM
Accidently removed the RPM DB rvbalraj Linux - Server 2 05-13-2008 09:41 PM
Accidently removed application bar amivit Slackware 3 10-24-2007 09:30 AM
accidently removed internet icon firedancer Ubuntu 3 08-07-2007 07:38 AM
HELP! accidently removed files RobHill Linux - General 2 06-01-2007 01:04 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 04:05 PM.

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