diff --git a/README.md b/README.md
index 764810769..5179a9b64 100644
--- a/README.md
+++ b/README.md
@@ -9,35 +9,63 @@ This repository contains implementation for the sonic system telemetry services:
### Prerequisites
-Install __go__ in your system https://golang.org/doc/install. Requires golang1.8+.
+* Install __go__ in your system https://golang.org/doc/install. Requires golang1.8+.
+* Install Git
+* Install Libpcre3-dev using:
+
+ sudo apt install -y libpcre3-dev
+
+* Install Customized version of libyang. These can obtained from a local sonic-buildimage folder and installed using the command:
-## Installing
-
-To install dial-in mode system telemetry server, run
+ sudo dpkg -i ${buildimage}/target/debs/stretch/libyang*.deb
- go get -u github.com/Azure/sonic-telemetry/telemetry
+ or they can be downloaded from Jenkins and installed individually. Libyang, Libyang-cpp, Libyang-dbg, and Libyang-dev all need to be installed. https://sonic-jenkins.westus2.cloudapp.azure.com/job/generic/job/buildimage-baseimage/lastSuccessfulBuild/artifact/sonic-buildimage/target/debs/buster/
+* Install PCRE http://www.pcre.org/ compiled with --enable-unicode-properties. A compiling guide can be found https://mac-dev-env.patrickbougie.com/pcre/
-To install dial-out mode system telemetry client, run
-
- go get -u github.com/Azure/sonic-telemetry/dialout/dialout_client_cli
+## Installing
-There is also a test program dialout_server_cli for collecting data from dial-out mode system telemetry client. _Note_: it is for testing purpose only.
+There is a test program dialout_server_cli for collecting data from dial-out mode system telemetry client. _Note_: it is for testing purpose only. Only Go is a prerequisite.
go get -u github.com/Azure/sonic-telemetry/dialout/dialout_server_cli
The binaries will be installed under $GOPATH/bin/, they may be copied to any SONiC switch and run there.
-You can also build a debian package and install it:
+To use the telemetry server or dial-out client you can build SONiC-telemetry into a debian package and install it using the following steps:
+ git clone https://github.com/Azure/sonic-mgmt-common.git
git clone https://github.com/Azure/sonic-telemetry.git
- pushd sonic-telemetry
- dpkg-buildpackage -rfakeroot -b -us -uc
- popd
+
+ cd sonic-mgmt-common
+ make
+ sudo dh_install -psonic-mgmt-common -P/-v
+
+
+ cd sonic-telemetry
+ make
+ sudo install testdata/database_config.json -t /var/run/redis/sonic-db <- sometimes the sonic-db folder must be created manually.
+ export CVL_SCHEMA_PATH=/usr/sbin/schema <- This must be performed everytime it is run.
+
+
+To test that it worked:
+
+ ./build/bin/telemetry --help
+
+Steps written with Ubuntu 18.04 in July 2020.
### Running
* See [SONiC gRPC telemetry](./doc/grpc_telemetry.md) for how to run dial-in mode system telemetry server
* See [SONiC telemetry in dial-out mode](./doc/dialout.md) for how to run dial-out mode system telemetry client
+### Common Errors
+| Error | Solution |
+| ----------------------- | ----------------------- |
+| sudo install testdata/database_config.json -t /var/run/redis/sonic-db
install: failed to access '/var/run/redis/sonic-db': No such file or directory | Manually create the missing folder (/var/run/redis/sonic-db) and try again |
+| ./build/bin/dialout_client_cli -insecure -logtostderr -v 1
libyang[0]: Unable to use search directory "schema/" (No such file or directory)
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x50 pc=0x958402] | Ensure that Ensure that CVL_SCHEMA_PATH is properly exported. export CVL_SCHEMA_PATH=/usr/sbin/schema must be run every time |
+| user@build:-/Desktop/sonic$ make -C sonic-telemetry
make: Entering directory '/home/user/Desktop/sonic/sonic-telemetry'
# FIXME temporary workaround for crypto not downloading..
/usr/local/go/bin/go get golang.org/x/crypto/ssh/terminal@e9b2fee46413
go: found golang.org/x/crypto/ssh/terminal in golang.org/x/crypto vO.O.O-20191206172530-e9b2fee46413
# golang.org/x/sys/unix../../../go/pkg/mod/golang.org/x/sys@v0.0.0-2020061520003
2-f1bc736245b1/unix/syscall unix.go: 16: 2: import /home/user/. cache/go - bui Id/08/08624f22b1129d677c1be2d3e3fe2b94a
f75a12b875aOc9b4e5c521fe24ff51e-d: reading input: EOF
Makefile: 33: recipe for target 'vendor/. done' failed
make: *** [vendor/. done] Error 2
make: Leaving directory '/home/user/Desktop/sonic/sonic-telemetry' | Package cache is corrupted. Delete $HOME/.cache/go-build and try again. If it still fails, delete /tmp/go/pkg directory as well.
+
+
+
+
## Need Help?
For general questions, setup help, or troubleshooting: