PKG Issues

jimhorner67

Dabbler
Joined
Jun 28, 2019
Messages
12
Hope someone can help. When i run pkg update or upgrade i get this error:
pkg: Error parsing /usr/local/etc/pkg/repos/FreeBSD.conf': memory: 2 unmatched open brace at 1
 
D

dlavigne

Guest
Are you running that on FreeNAS itself or within a jail?

Which version of FreeNAS?
 

Jailer

Not strong, but bad
Joined
Sep 12, 2014
Messages
4,977
Are you running the command in a jail? Also please list your complete system specs.
 

jimhorner67

Dabbler
Joined
Jun 28, 2019
Messages
12
Running it in a Jail.
OS Version:
FreeNAS-11.2-U6
(Build Date: Sep 17, 2019 0:16)
Processor:
Intel(R) Xeon(R) CPU E3-1225 V2 @ 3.20GHz (4 cores)
Memory:
16 GiB
HostName:
freenas.local
Uptime:
6:43AM up 2:24, 0 users
 

jimhorner67

Dabbler
Joined
Jun 28, 2019
Messages
12
I created a jail for Plex. been running fine ...just when i go to update the jail i get that error
 

anmnz

Patron
Joined
Feb 17, 2018
Messages
286
I'm guessing you updated /usr/local/etc/pkg/repos/FreeBSD.conf inside the jail, in order to use the "latest" package repo instead of "quarterly" so you'd get more recent versions of Plex, and introduced a typo into it.

What is the content of that file inside the jail where you're running pkg commands?
 

anmnz

Patron
Joined
Feb 17, 2018
Messages
286
I was suggesting that there was a typo in that file, because your error message said "unmatched open brace". We'd need to see the whole content of the file in order to check that.
 

jimhorner67

Dabbler
Joined
Jun 28, 2019
Messages
12
I was suggesting that there was a typo in that file, because your error message said "unmatched open brace". We'd need to see the whole content of the file in order to check that.

root@PMS_A:/ # cat /usr/local/etc/pkg/repos/FreeBSD.conf
FreeBDS: { enable: no :
root@PMS_A:/ #
 

anmnz

Patron
Joined
Feb 17, 2018
Messages
286
root@PMS_A:/ # cat /usr/local/etc/pkg/repos/FreeBSD.conf
FreeBDS: { enable: no :
root@PMS_A:/ #
If that's really what you get when you run that command, then (a) you've misspelled "FreeBSD" and (b) you've lost everything that's supposed to be in that file after the first line, which would explain the error message.

One thing you could do is just delete the file and see if that makes the problem go away.

Then if you want to create it again, follow whatever instructions you were following before when you created it the first time, but be careful to get the content of the file right. E.g. check with "cat" again that it's exactly what it's supposed to be.
 

jimhorner67

Dabbler
Joined
Jun 28, 2019
Messages
12
root@PMS_A:/ # pkg -vv
pkg: Error parsing: '/usr/local/etc/pkg/repos//FreeBSD.conf': memory:2 unmatched open brace at 1;
Version : 1.11.1
PKG_DBDIR = "/var/db/pkg";
PKG_CACHEDIR = "/var/cache/pkg";
PORTSDIR = "/usr/ports";
INDEXDIR = "";
INDEXFILE = "INDEX-11";
HANDLE_RC_SCRIPTS = false;
DEFAULT_ALWAYS_YES = false;
ASSUME_ALWAYS_YES = false;
REPOS_DIR [
"/etc/pkg/",
"/usr/local/etc/pkg/repos/",
]
PLIST_KEYWORDS_DIR = "";
SYSLOG = true;
ABI = "FreeBSD:11:amd64";
ALTABI = "freebsd:11:x86:64";
DEVELOPER_MODE = false;
VULNXML_SITE = "http://vuxml.freebsd.org/freebsd/vuln.xml.bz2";
FETCH_RETRY = 3;
PKG_PLUGINS_DIR = "/usr/local/lib/pkg/";
PKG_ENABLE_PLUGINS = true;
PLUGINS [
]
DEBUG_SCRIPTS = false;
PLUGINS_CONF_DIR = "/usr/local/etc/pkg/";
PERMISSIVE = false;
REPO_AUTOUPDATE = true;
NAMESERVER = "";
HTTP_USER_AGENT = "pkg/1.11.1";
EVENT_PIPE = "";
FETCH_TIMEOUT = 30;
UNSET_TIMESTAMP = false;
SSH_RESTRICT_DIR = "";
PKG_ENV {
}
PKG_SSH_ARGS = "";
DEBUG_LEVEL = 0;
ALIAS {
all-depends = "query %dn-%dv";
annotations = "info -A";
build-depends = "info -qd";
cinfo = "info -Cx";
comment = "query -i \"%c\"";
csearch = "search -Cx";
desc = "query -i \"%e\"";
download = "fetch";
iinfo = "info -ix";
isearch = "search -ix";
prime-list = "query -e '%a = 0' '%n'";
prime-origins = "query -e '%a = 0' '%o'";
leaf = "query -e '%#r == 0' '%n-%v'";
list = "info -ql";
noauto = "query -e '%a == 0' '%n-%v'";
options = "query -i \"%n - %Ok: %Ov\"";
origin = "info -qo";
provided-depends = "info -qb";
rall-depends = "rquery %dn-%dv";
raw = "info -R";
rcomment = "rquery -i \"%c\"";
rdesc = "rquery -i \"%e\"";
required-depends = "info -qr";
roptions = "rquery -i \"%n - %Ok: %Ov\"";
shared-depends = "info -qB";
show = "info -f -k";
size = "info -sq";
}
CUDF_SOLVER = "";
SAT_SOLVER = "";
RUN_SCRIPTS = true;
CASE_SENSITIVE_MATCH = false;
LOCK_WAIT = 1;
LOCK_RETRIES = 5;
SQLITE_PROFILE = false;
WORKERS_COUNT = 0;
READ_LOCK = false;
PLIST_ACCEPT_DIRECTORIES = false;
IP_VERSION = 0;
AUTOMERGE = true;
VERSION_SOURCE = "";
CONSERVATIVE_UPGRADE = true;
PKG_CREATE_VERBOSE = false;
AUTOCLEAN = false;
DOT_FILE = "";
REPOSITORIES {
}
VALID_URL_SCHEME [
"pkg+http",
"pkg+https",
"https",
"http",
"file",
"ssh",
"ftp",
"ftps",
"pkg+ssh",
"pkg+ftp",
"pkg+ftps",
]
ALLOW_BASE_SHLIBS = false;
WARN_SIZE_LIMIT = 1048576;
METALOG = "";
OSVERSION = 1102000;
IGNORE_OSVERSION = false;


Repositories:
FreeBSD: {
url : "pkg+http://pkg.FreeBSD.org/FreeBSD:11:amd64/quarterly",
enabled : yes,
priority : 0,
mirror_type : "SRV",
signature_type : "FINGERPRINTS",
fingerprints : "/usr/share/keys/pkg"
}
root@PMS_A:/ #
 

jimhorner67

Dabbler
Joined
Jun 28, 2019
Messages
12
If that's really what you get when you run that command, then (a) you've misspelled "FreeBSD" and (b) you've lost everything that's supposed to be in that file after the first line, which would explain the error message.

One thing you could do is just delete the file and see if that makes the problem go away.

Then if you want to create it again, follow whatever instructions you were following before when you created it the first time, but be careful to get the content of the file right. E.g. check with "cat" again that it's exactly what it's supposed to be.


Thanks for the help...not real sure how to del that without screwing things up more. May just do a fresh install of Freenas. I only use it to run PLEX
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
not real sure how to del that without screwing things up more.
If you're going to be messing around at the command line (which you obviously have been), it would be worth your time to learn at least a few basic *nix commands. To delete files, use the rm command (for "remove"). rm /usr/local/etc/pkg/repos/FreeBSD.conf.
 

jimhorner67

Dabbler
Joined
Jun 28, 2019
Messages
12
If you're going to be messing around at the command line (which you obviously have been), it would be worth your time to learn at least a few basic *nix commands. To delete files, use the rm command (for "remove"). rm /usr/local/etc/pkg/repos/FreeBSD.conf.


I know people like me drive you guys nuts so i appreciate the help.
 

Jailer

Not strong, but bad
Joined
Sep 12, 2014
Messages
4,977
Top