Git Product home page Git Product logo

packaging's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

packaging's Issues

snap: Enable ppc on launchpad

It would be nice to enable ppc on launchpad. However, it seems to fail:

+ echo Running tests ...
+ bitcoin-22.0/bin/test_bitcoin
Running tests ...
/bin/sh: 53: bitcoin-22.0/bin/test_bitcoin: not found
Failed to run 'override-build': Exit code was 127.
Build failed

--
https://launchpad.net/~bitcoin-core/+snap/bitcoin-core-snap-main/+build/1737883

snap:

how to synchronize the network quicker /?

add :removable-media

Would that make sens to add :remouvable-media in plugs to ease the conenction to external hard drive ?

Fork master into 22.0 branch

$TITLE says it all

It seems there were branches created for earlier versions (0.21, 0.20, 0.19, 0.18, etc.). Let's do the same for 22.0 - some distributions (e.g. NixOS) are expecting the branch to exist.

De-facto the same issue as #59 but for the new 22.0 release

sync slowness with 0.17.0.1 snap

Issue was reported on reddit about slowness using a 0.17.0.1 snap, presumably referring to the current stable snap (bitcoin_335.snap):

channels:
  stable:    0.17.0.1 2018-12-13 (335) 122MB -

https://www.reddit.com/r/Bitcoin/comments/aos8bk/huge_performance_difference_doing_the_blockchain/

I tried rolling back to 0aedf52 and rebuilding the 0.17.0.1 snap to see if there might be something obviously wrong with it like being configured without assembly code. From build output at https://gist.github.com/ryanofsky/397835e4d78f1a1274a841735809afa7 this didn't seem to be the case and no other obvious problem jumped out. Since we haven't uploaded our own snaps yet (we are waiting for the snapcraft security team to allow this), it's possible the present bitcoin_335.snap was built differently, but more likely we will need to do some actual debugging / profiling of the snap build to try to reproduce and fix this.

snap:

my hard drive was crashed ..i have managed to save wallet.dat (it is 10 years old)
i have tried to download whole block chain through bitcoin core...but it is very slow.
kindly tell me how can i recover my bitcoin from wallet.dat file ?
and haw to download fast whole block chain ?

kindly help me

Bitcoin Core Snap on Ubuntu: Tiny font size

The current Bitcoin Core Snap renders it's dialogs in ~5 pt text. For me, this is unreadable. See screenshot below.

Some system info:

$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.2 LTS
Release:	20.04
Codename:	focal

$ apt list --upgradable 
Listing... Done

$ snap list
Name          Version    Rev    Tracking       Publisher     Notes
bitcoin-core  0.21.0     87     latest/stable  bitcoin-core  -
core          16-2.49.2  10958  latest/stable  canonical✓    core

Screenshot from 2021-05-05 18-42-27

Snap: bitcoin-core doesn't accept requests from rust bitcoincore-rpc

Running a snap bitcoin-core node I was able to make requests via curl successfully. However, when using the rust crate: https://docs.rs/bitcoincore-rpc/latest/bitcoincore_rpc/index.html to query the same requests it fails with 400 Bad Request.

I've tested the rust code against other nodes, both remote, hosted nodes, and local nodes on baremetal and in docker, and the one packaged for snap is the only one that has problems.

Code to reproduce:

#[test]
fn test() {
	let client = Client::new(
		&"http://my-node:port",
		Auth::UserPass("user".to_string(), "password".to_string()),
	)
	.unwrap();

	client.get_best_block_hash().unwrap();
}

Issue after rebooting system

I install Bitcoin core on my raspberry PI 5 8GB (ubuntu) and all works great..now after a system restart, when i run BTC core, it stuck on "Loading block index.." gradually fulling the RAM and when is full it shut down itself..i try to reinstall the client but it doesn't solve..someone can help me please?

Snap install on Unity UI has qt menu bar missing

Screenshot from 2019-05-15 10-03-53
No menu bar is present - makes bitcoin-core.qt mostly unusable.

Confirmed bug on two 16.04 ubuntu installations.
Another qt application when installed with snap had similar but not as severe issue (2048-qt-snap).

Downloading the btc core 18.0 tar.gz and running bitcoin-qt results in menu bar at the top of the screen as one would expect in 16.04.

Could be related to 16.04 putting the menu bar at the top of the screen instead of inside the application window perhaps?

Installing via snap works fine in newer versions of ubuntu of course.

Run as a service

Hi,

How can I set up the snap packge to start bitcoind automatically? I'm having trouble running bitcoin-core.daemon as a service on CentOS. It seems snap (i.e. SELinux) won't let systemd read the binary file bitcoin-daemon that lives inside the snap container. Please find logs and service file below. Any help is greatly appreciated.

Also, I've just learned there's a thing called a "snap services" (docs). Perhaps that'd be the best way to move forward? In that case, perhaps we should consider adding a service configuration to this repo?

Thanks in advance.

journalctl -xe
setroubleshoot[3079]: AnalyzeThread.run(): Set alarm timeout to 10
setroubleshoot[3079]: AnalyzeThread.run(): Cancel pending alarm
setroubleshoot[3079]: failed to retrieve rpm info for /var/lib/snapd/snap/bin/bitcoin-core.daemon
setroubleshoot[3079]: SELinux is preventing /usr/lib/systemd/systemd from read access on the lnk_file /var/lib/snapd/snap>

                      *****  Plugin catchall (100. confidence) suggests   **************************

                      If you believe that systemd should be allowed read access on the bitcoin-core.daemon lnk_file by de>
                      Then you should report this as a bug.
                      You can generate a local policy module to allow this access.
                      Do
                      allow this access for now by executing:
                      # ausearch -c '(e.daemon)' --raw | audit2allow -M my-edaemon
                      # semodule -X 300 -i my-edaemon.pp

/etc/systemd/system/bitcoind.service
[Unit]
Description=Bitcoin daemon
After=network.target

[Service]
ExecStart=/var/lib/snapd/snap/bin/bitcoin-core.daemon -daemon -pid=/home/bitcoin/.bitcoin/bitcoind.pid -conf=/home/bitcoin/.bitcoin/bitcoin.conf -datadir=/home/bitcoin/.bitcoin

# Make sure the config directory is readable by the service user
ExecStartPre=+/bin/chgrp bitcoin /home/bitcoin/.bitcoin

# Process management
####################

Type=forking
PIDFile=/home/bitcoin/.bitcoin/bitcoind.pid
Restart=on-failure
TimeoutStopSec=600

# Directory creation and permissions
####################################

# Run as bitcoin:bitcoin
User=bitcoin
Group=bitcoin

[Install]
WantedBy=multi-user.target

snap: AppArmor spam in dmesg

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 21.10
Release:        21.10
Codename:       impish
$ snap info bitcoin-core
snap-id:      lGr3hNoqLtHTp2yV1BgnqyElQtLUDPeA
tracking:     latest/stable
refresh-date: 2 days ago, at 05:23 +05
...
installed:          22.0              (99) 107MB -

Each minute:

[Fri Nov 19 11:02:18 2021] audit: type=1400 audit(1637301739.161:950): apparmor="DENIED" operation="open" profile="snap.bitcoin-core.daemon" name="/proc/diskstats" pid=27297 comm="b-scheduler" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
[Fri Nov 19 11:02:18 2021] audit: type=1400 audit(1637301739.161:951): apparmor="DENIED" operation="open" profile="snap.bitcoin-core.daemon" name="/proc/vmstat" pid=27297 comm="b-scheduler" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
[Fri Nov 19 11:02:18 2021] audit: type=1400 audit(1637301739.161:952): apparmor="DENIED" operation="open" profile="snap.bitcoin-core.daemon" name="/proc/schedstat" pid=27297 comm="b-scheduler" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
[Fri Nov 19 11:02:18 2021] audit: type=1400 audit(1637301739.161:953): apparmor="DENIED" operation="open" profile="snap.bitcoin-core.daemon" name="/proc/zoneinfo" pid=27297 comm="b-scheduler" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
[Fri Nov 19 11:02:18 2021] audit: type=1400 audit(1637301739.161:954): apparmor="DENIED" operation="open" profile="snap.bitcoin-core.daemon" name="/proc/softirqs" pid=27297 comm="b-scheduler" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
[Fri Nov 19 11:02:18 2021] audit: type=1400 audit(1637301739.161:955): apparmor="DENIED" operation="open" profile="snap.bitcoin-core.daemon" name="/proc/27297/schedstat" pid=27297 comm="b-scheduler" requested_mask="r" denied_mask="r" fsuid=1000 ouid=1000

probably because of /src/randomenv.cpp

۷۸۹

$ ./autogen.sh
$ ./configure
$ make
$ sudo make install

Fork master into 0.21 branch

$TITLE says it all

It seems there were branches created for earlier versions (0.20, 0.19, 0.18, etc.). Let's do the same for 0.21 - some distributions (e.g. NixOS) are expecting the branch to exist.

snap: bitcoin-core 0.20.0

hello developers, on linux ubuntu i can not select any drive or folder for 300GB blockchain data. my ubuntu is installed on expensive 256GB nvme, I have cheap old 1TB harddisc for other stuff and blockchain but the application dont show any folders and discs. it says choose data directory but there is nothing to select.

fail

Bitcoin-Core 0.20.0 - Network Folders, Already Present Chain, Inability to Change Folder Choice.

I installed the snap to a machine where I have an NFS mounted folder in my $HOME directory. That folder is already populated with some 320GB of blocks. I'm having multiple issues:

  1. There is no indication on first run that my already present chain won't be overwritten:

    As this is the first time the program is launched, ... Bitcoin Core will download and store a copy of the Bitcoin block chain.... The wallet will also be stored in this directory.
    [ ] use the default data directory
    [x] use a custom data directory

    When you click OK, Bitcoin Core will begin to download and process the full Bitcoin block chain (320GB) ....
    [ ] Discard blocks after verification, except most recent 2 GB (prune)

  2. When I select the .bitcoin directory, it tells me the amount of space available, which is less than what is needed to download the whole chain. That, of course, should be irrelevant as I already have it.

  3. When I cross my fingers and try to run anyway, I get a permission error. I suspect that error is from the snap, because I was using just that folder (though not network mounted) with the Bitcoin Ubuntu PPA version, and it was working. Also, on a different machine, I run Bitcoin-ABC (also from an Ubuntu PPA) on a network mounted directory structure with identical permissions, and it works fine.

  4. I try sudo snap connect bitcoin-core:removable-media, even though my mounts are not in /media, and find it doesn't work.

  5. I look in vain for a way to change the directory I had chosen, thinking I might move the mount to /media, but Bitcoin-Core doesn't give me the option. I see I'll have to uninstall and reinstall.

  6. I conclude I better look for help.

problem creating /var/lib/bitcoin with ppa on ubuntu 14.04

I just updated bitcoin using your ubuntu ppa. I think I was running version 0.15.x before the update. I'm on ubuntu 14.04. During this update, I noticed that it created a new bitcoin user and group. Is there a specific reason for this? Are you trying to move to a situation where it runs as a service instead of manually by the current user? Also, something failed with this new user setup because it says the home folder it was looking for doesn't exist and it didn't create it.

Setting up bitcoin-tx (0.17.1-trusty1) ...
Setting up bitcoind (0.17.1-trusty1) ...
Installing new version of config file /etc/bash_completion.d/bitcoind ...
Warning: The home dir /var/lib/bitcoin you specified can't be accessed: No such file or directory
Adding system user bitcoin' (UID 119) ... Adding new group bitcoin' (GID 127) ...
Adding new user bitcoin' (UID 119) with group bitcoin' ...
Not creating home directory `/var/lib/bitcoin'.

snap:

Icon that is generated does not work.

Problem updating with Ubuntu PPA

Attempting to update bitcoind from 0.16.0-xenial1 to 0.16.2-xenial1 on Ubuntu 16.04.5 LTS using the PPA gives me two errors:

  1. For a missing directory (/var/lib/bitcoin), and
  2. For adduser: The user `bitcoin' already exists.

The installation therefore does not successfully complete:

dpkg: error processing package bitcoind (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 bitcoind
E: Sub-process /usr/bin/dpkg returned an error code (1)

I've previously updated to 0.16.0 using this PPA without any problems.

snap: bitcoin-core cannot access filesystems other than root

I need to have my datadir off root or it will fill up. However bitcoin core cannot access my other filesystems. cli reports no such file or directory and in the gui there is no option to select other filesystems or symbolic links.

This is on Ubuntu 22.04 LTS

Issues running snap on Ubuntu

After installing the bitcoin-core snap, the Bitcoin Core GUI is not available in Unity’s dashboard.
I managed to find and launch bitcoin-core.qt from the terminal, but it seems it doesn’t manage hardlinks, and is returning an error because it doesn’t find my files anymore. Also it has ignored my previous /home/user/.config/Bitcoin and is giving me the "New install" screen. So that’s a no show for me.

'bitcoin-core.qt
ERROR: ld.so: object 'libgtk3-nocsd.so.0' from LD_PRELOAD cannot be
preloaded (failed to map segment from shared object): ignored.
/home/ao/Téléchargements was removed, reassigning DOWNLOAD to homedir'

snap: Desktop file didn't specify Exec field

snap failure cropped

I installed the snap via the Ubuntu Software Store on 19.04 and attempted to run via the search (Super>"bitcoin")

Tried uninstalling and running via command line and got:

error: cannot perform the following tasks:
- Fetch and check assertions for snap "bitcoin-core" (32) (cannot verify snap "bitcoin-core", no matching signatures found)

I have found however that you can run it with

snap run bitcoin-core.qt

snap: Bump to bionic

Apparently xenial is slowly dying, so it might be good to bump our snap base to bionic or focal before it is taken offline.

See previous (now stale) attempts: #12, #10, ...

snap: All snap versions mistakenly marked as "stable"

I believe that the current situation where v24.0.1 as well as v22.1 and other versions are all marked as stable is wrong: https://snapcraft.io/bitcoin-core

This is especially true for the 0.x versions that are already End of Life according to this: https://bitcoincore.org/en/lifecycle/#schedule

Kindly remove or mark the older versions (0.x) as obsolete (EOL) and clearly indicate whether the 23.1 is the latest/stable or if it's the 24.0.1

Note:
This is NOT a follow up on the discussion whether there should be a zero at the front of the release or not as previously discussed here:
bitcoin/bitcoin#20223
IRC chat: https://www.erisian.com.au/meetbot/bitcoin-core-dev/2020/bitcoin-core-dev.2020-10-22-18.59.log.html#l-122

Curious why there is no official bitcoind Docker image?

As the title states, I'm curious why there are no official Docker images for bitcoind. Even if there are no pre-built official images hosted on a third-party hub (due to security), at least an official Dockerfile and instructions to build locally would be nice.

Right now, users running Bitcoin in Docker are using community-provided images. Though these images are good and the code to build them is open, I would imagine for a product that takes application integrity seriously, providing official Docker images would be a priority. How many people are really installing Bitcoin via Snap or Flatpak compared to using Docker?

Docker can also be used to cross-build images for multiple architectures.
https://github.com/lncm/docker-bitcoind

I found #2, but it was closed without anything being merged. Is it just a matter of getting the initial file in there?

.

sorry. posted by mistake. pls delete.

snap: tor's cookie file not visible for Bitcoin Core

My OS is Ubuntu 22.04 and Bitcoin Core v23.0.0 is installed via the official snap package. Tor 0.4.7.8 is installed from official torproject.org deb repo.

/etc/tor/torrc contains:

ControlPort 9051
CookieAuthentication 1
CookieAuthFileGroupReadable 1

Regarding tor and such ~/snap/bitcoin-core/common/.bitcoin/bitcoin.conf contains:

# Network
listen=1
listenonion=1
proxy=127.0.0.1:9050
bind=127.0.0.1
debug=tor

The user account which runs Bitcoin Core is member of the debian-tor group and I have verified that the file
/run/tor/control.authcookie is readable for my user account. So no filesystem permission issue here. The cookie file has sufficient permissions to be readable for Bitcoin Core running with my user account.

Unfortunately this doesn't seem to work with the snap isolation as the following issue is still logged in Core's debug.log:

2022-06-24T07:52:03Z tor: Supported authentication method: COOKIE
2022-06-24T07:52:03Z tor: Supported authentication method: SAFECOOKIE
2022-06-24T07:52:03Z tor: Using SAFECOOKIE authentication, reading cookie authentication from /run/tor/control.authcookie
2022-06-24T07:52:03Z tor: Authentication cookie /run/tor/control.authcookie could not be opened (check permissions)

Sorry, I don't know much about snaps but I suspect maybe a system file interface is missing to allow Core to access and read files in /run/tor/ directory?

Bitcoin Core synchronizes and connects to peer but it seems to me it can't setup a hidden tor service and is likely not accessible via an onion address. At least I don't see anything in the logs that indicate such.
I'll gladly provide any additional information that I might have missed to give here for now and appreciate any help. I can do additional tests or tweaks if needed, just provide me some details what you would like me to do.

snap: Additional verification of the Bitcoin Core snap package needed (hash missing)

I propose that together with each release there is SHA256 hash published of the installed client binary so people can easily run SHA256 binary files verification on their machine therefore we have better chance to avoid situations like this: https://twitter.com/LukeDashjr/status/1609937505217904642

I'm aware that people can download the Bitcoin Core source code and compile it themselves but let's face it - few people actually want to do that and the vast majority will use the binary (from some place) so let's give them a fighting chance to defend themselves in a realistic way.

.

NGUYỄN NHÂN

Make ppa use deterministic release builds

There has been a discussion about this on IRC:

http://www.erisian.com.au/bitcoin-core-dev/log-2020-03-12.html#l-383

[15:25] <dongcarl> Very naive thought: is it possible to have 2 PPAs, 1 for gitian built binaries, 1 for specifically OS-integrated?
[15:25] <luke-jr> achow101: absolutely
[15:26] <MarcoFalke> dongcarl: I'd support that
[15:26] <luke-jr> achow101: PPAs are not a replacement for gitian, they are an alternative for certain users
[15:26] <luke-jr> dongcarl: should be
[15:26] <MarcoFalke> bitcoin/bitcoin would be deterministic and luke-jr/bitcoin is built with system libs
[15:26] <luke-jr> dongcarl: sounds like a good idea, even
[15:26] <luke-jr> MarcoFalke: that seems backward
[15:26] <luke-jr> bitcoin/bitcoin has always been system libs
[15:27] <sipa> luke-jr: you seem to be the only one arguing for system libs
[15:27] <luke-jr> sipa: so?
[15:27] <achow101> I think anything "official" should only be determinisitic
[15:27] <MarcoFalke> agree
[15:27] <sipa> agree
[15:27] <wumpus> achow101: +1

Enable "external" datadirs in snap package

Selecting a datadir that is not the default will result in a permission error. See reports #21 (comment) or https://twitter.com/rusty_twit/status/1201368196608999424

This can be solved by adding the "right" interface. There is the home interface https://snapcraft.io/docs/home-interface or https://snapcraft.io/docs/personal-files-interface or https://snapcraft.io/docs/removable-media-interface or https://snapcraft.io/docs/system-files-interface

As the snap dir already resides in the home dir, I am not sure how much the home interface is going to help. And Bitcoin Core generally does not support storing data on removable media, as it is a common cause for data corruption. I guess the removable-media-interface also gives access to "permanent" secondary disks, so I wouldn't object adding that interface.

Bitcoin daemon - issue after replacing wallet.dat

I'm using Bitcoin core 0.20 on Ubuntu 18.
After replacing wallet.dat with my older one, after starting Bitcoin Core it kept "Loading block" and "Loading index".
These errors started appearing in In /home/[user]/snap/bitcoin-core/common/.bitcoin/wallets/db.log:

temporary open: /var/tmp/BDB05682: Permission denied
unable to create temporary backing file
temporary open: /var/tmp/BDB05729: Permission denied
unable to create temporary backing file

I'm launching bitcoind using a systemd unit I created.
I don't know why there's permission problems. I'm able to access /var/tmp/ with the same user and create files inside. it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.