Removed /root/.cabal by mistake - how to solve this issue?


 
Thread Tools Search this Thread
Top Forums Programming Removed /root/.cabal by mistake - how to solve this issue?
# 1  
Old 06-07-2015
Removed /root/.cabal by mistake - how to solve this issue?

I have mistakenly removed /root/.cabal/ from my root directoty and when I tried to reinstall it I get this output:

Code:
faiz:~$ sudo cabal install pandoc --reinstall
Resolving dependencies...
In order, the following will be installed:
pandoc-1.14.0.4 (reinstall)
Warning: Note that reinstalls are always dangerous. Continuing anyway...
[1 of 1] Compiling Main             ( /tmp/pandoc-1.14.0.4-7040/pandoc-1.14.0.4/Setup.hs, /tmp/pandoc-1.14.0.4-7040/pandoc-1.14.0.4/dist/setup/Main.o )
Linking /tmp/pandoc-1.14.0.4-7040/pandoc-1.14.0.4/dist/setup/setup ...
Configuring pandoc-1.14.0.4...
Building pandoc-1.14.0.4...
Preprocessing library pandoc-1.14.0.4...

src/Text/Pandoc.hs:183:8:
Could not find module `Text.Parsec.Error'
There are files missing in the `parsec-3.1.9' package,
try running 'ghc-pkg check'.
Use -v to see a list of the files searched for.
cabal: Error: some packages failed to install:
pandoc-1.14.0.4 failed during the building phase. The exception was:
ExitFailure 1

The problem, I believe has to deal with Haskell installation. I have no experience with Haskell, and I only need a package called "pandoc" for some work with R. What should I do to reinstall pandoc again? I also want to know what's the difference in installing pandoc (using cabal) from the root command line (#) and installing it using the sudo command? (sudo cabal install pandoc.) I use a netbook that has crunchbang linux (basically Debian Wheezy)

Last edited by faizlo; 06-07-2015 at 03:24 AM.. Reason: add more info
# 2  
Old 06-07-2015
I'm guessing you do no have a backup.

We cannot know particulars, but try to uninstall as much as possible. You are in a situation where you have pieces of an application installer/application already on the system.

Displaying my ignorance: /root/.cabal <- is this the default path for the application?

The differences in how you run are determined - if there are any - by the /etc/sudoers file. I am assuming a vanilla install of sudo.
# 3  
Old 06-07-2015
Thanks for the reply. No, I don't have a backup. I first installed cabal-install and cabal-debian then I installed pandoc. For some reason (not a sane one for sure) I deleted /root/.cabal/ and as you said, my system still thinks it is still there. I was hoping to find out what causes my system to still think it is still there. /root/.cabal contained a .config/ folder which is not there any more so I do not know what to do. Reinstalling also gives error.

---------- Post updated at 03:00 PM ---------- Previous update was at 02:27 PM ----------

Solved!

Since I removed (deleted) the /root/.cabal/ directory (by mistake) my system could still detect that some other packages were there and as a result complained that the system already has the required packages and files. This was because of the /root/.ghc/ folder which was still there. removing this folder, and the two corresponding local folders ~/.cabal and ~/.ghc and using cabal install pandoc solved my issue.
This User Gave Thanks to faizlo For This Post:
# 4  
Old 06-07-2015
Thanks for telling us the solution. It may help others in the future.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. What is on Your Mind?

Man Pages - Removed Table Tags and Fixed Scrollbar Issue

OK. I fixed the horizonal scroll bar issues in the man pages pre format output for the man pages by removing all table tags and converting to divs: https://www.unix.com/members/1-albums220-picture876.png I still have some work to do on reformatting the deep search redirects and the... (0 Replies)
Discussion started by: Neo
0 Replies

2. Shell Programming and Scripting

How to solve hang issue in script?

i have one function block in the beginning of my script and there are some commands inside that function which will perform some operations. And i am invoking that function from my main script by passing some values. Sometimes it is hanging in the middle for some value. For example: For 1st... (3 Replies)
Discussion started by: thomasraj87
3 Replies

3. Shell Programming and Scripting

Can't solve a simple SSH/scp issue.. Please help.

Disclaimer: I tried searching but wasn't able to get to the answer so please don't flame. Scenario: I have a root script that generates a file on box1 and then needs to scp it over to box2 using user1. Both boxes are running open-ssh. root@locat-host# scp /tmp/file1 user1@box2:/tmp/file1 ... (10 Replies)
Discussion started by: denissi
10 Replies

4. Shell Programming and Scripting

Request to checkVenn diagram issue solve by Unix programm

Hello Any Unix programm can help me to solve thsi issue: I have 2 venn digrams please checke the attached file for pictures of venn diagram for eg red is A yellow is B and green is C..Please see attached file for Venn diagrams In one ..... I have 3 data set A , B and C Venn diagram... (0 Replies)
Discussion started by: manigrover
0 Replies

5. Solaris

ZFS root Issue

I jumpstarted a solaris sun4u box from WANboot and it completed but while coming up it gives following error and panics Use is subject to license terms. NOTICE: zfs_parse_bootfs: error 48 Cannot mount root on rpool/47 fstype zfs panic/thread=180e000: vfs_mountroot: cannot mount root ... (0 Replies)
Discussion started by: fugitive
0 Replies

6. UNIX for Dummies Questions & Answers

Can anyone solve this awk issue ?

awk -F^ '{ if (($1 != "X") && ($5 != "3")) || if (($1 != "S") && ($5 != "2")) print $0}' abc> xyz The above command returns this error awk: syntax error near line 1 awk: illegal statement near line 1 I am newbie to awk, Any awk intelligence involved in correcting this issue is highly... (2 Replies)
Discussion started by: karthickrn
2 Replies

7. Solaris

please help me solve this issue.........

Hi, I am having a Solaris 5.9 server in which an audit trail script is running every day.It is doing nothing but taking the backup of three files given below -rw-r--r-- 1 root root 1807 May 18 01:30 login_server1_17May2008 -rw-r--r-- 1 root root 0 May 18 01:30... (5 Replies)
Discussion started by: Renjesh
5 Replies

8. Solaris

Help me to solve this issue

Hi, I want to send a .tar file from one solaris 5.9 server to another server in order to make files in sync.What method i can use? (2 Replies)
Discussion started by: Renjesh
2 Replies

9. Shell Programming and Scripting

solve temporary root password

Hi everybody! I'm italian and I'm new on this forum :D I have a question. Every day in my office root's servers password are modified temporary. I want create a script that: -set tmp password root (I insert tmp password from input standard) -after 24h tmp root password switch to prod... (1 Reply)
Discussion started by: go3mon
1 Replies

10. Solaris

Canīt issue commands as root

Hello all, I am having a problem with a Solaris 8 machine. Since 3 days ago I canīt login as root. I am able to login as a normal user and su. But as soon as I issue any command the system stop responding. If I log again as a normal user I see the process still runnig. Something I noticed,... (1 Reply)
Discussion started by: kik_xxx
1 Replies
Login or Register to Ask a Question