How to install AzureRM and AZ module using PowerShell 5.1? - azure-powershell

I am trying to install Az module on my windows server 2016 via PowerShell but it is giving me the error shown in the screenshot below.
It gives same error when tried on Windows 10 server as well.
If I try to install Azure RM command still the same error.
I have .Net Framework 4.8 present on Windows 2016 server and .Net 4.7 on Windows 10 server.
The PS version is 5.1 on both the server.
I tried referring couple solutions mentioned on multiple sites but no one seems to work.
Can anyone please let me know what am I missing or how can I resolve this error?

I used to get these errors a lot back in the day.
Try to run this:
Find-Module PowerShellGet | Install-module
if not this should work:
[Net.ServicePointManager]::SecurityProtocol = [Net.ServicePointManager]::SecurityProtocol -bor [Net.SecurityProtocolType]::Tls12
Register-PSRepository -Default -Verbose
Set-PSRepository -Name "PSGallery" -InstallationPolicy Trusted
Then you should be able to install the module.
ref: https://techcommunity.microsoft.com/t5/windows-powershell/trying-to-install-module-azuread-but-get-psrepository-quot/m-p/202819

Related

cygwin and BQ CLI not working... "-bash: bq: command not found"

I'm trying to script the loading of some data into GCP using the command line interface and I'm having an issue with cygwin with what i believe is a not complete install of BQ CLI.
From a DOS prompt I'm able to successfully run commands and load data so I believe I have it installed correctly on my desktop, Windows 10 64bit.
Is there some additional installation required to get cygwin to work correctly with BQ CLI that isn't installed by default with cygwin?
Appreciate any assistance.
I found the problem I was having... I was attempting to execute BQ from the cli using 'bq' and not 'bq.cmd'...
Working fine now...

Server not starting in IBM API connect toolkit

I have created API's in API connect toolkit. For testing the API locally in Explore tab, I am trying to start server.
But getting "Error: It appears that Docker for Windows has not been installed. To install Docker for Windows, please visit https://docs.docker.com/docker-for-windows/install/ For more information, check the docs" error.
From my understanding you don't need docker to test locally in toolkit. Any suggestions to fix the issue?
More Info: APIC version: API Connect: v5.0.8.3 (apiconnect: v2.7.209) NPM version : 6.1.0
It used to work before suddenly I am getting the above error. I tried re-installing but issue persist.
With new versions of APIC you must have Docker installed and working properly on your Windows environment to be able to install the API Connect Toolkit with DataPower.
Please find the steps to install the APIC toolkit on these pages:
https://www.ibm.com/support/knowledgecenter/en/SSFS6T/com.ibm.apic.toolkit.doc/tapim_cli_install.html
https://www.ibm.com/support/knowledgecenter/en/SSFS6T/com.ibm.apic.toolkit.doc/tapim_apic_test_with_dpdockergateway.html

Where is swagger cli on windows

I just ran 'npm install -g swagger' on my Windows 8 box and it seems to have run successfully, but when I try and run the swagger CLI, as per https://www.npmjs.com/package/swagger, it doesn't know where it's at.
How do I get to that tool?
For windows 10 swagger gets installed as A NODE module under
C:\Users`your name`\AppData\Roaming\npm\node_modules\swagger
you will also see the following entries under :
C:\Users`your name`\AppData\Roaming\npm
- swagger.cmd
- swagger-project.cmd
hope this helps

Install SQL Server ODBC Driver for Ubuntu 15.10

To install the ODBC Driver, I followed this tutorial: https://msdn.microsoft.com/en-us/library/hh568454(v=sql.110).aspx
But when I run "sudo bash ./install.sh install --force" I get this message
Then I launched this:
What have I to do to avoid the "not found" message for "libodbcinst.so.2" and for "libgss.so.3" ?
The tutorial states:
Before you can begin to use the driver, install the unixODBC driver manager
Do you have unixODBC installed?
It means that the right version of unixODBC (read: the one required by MS ODBC driver for Linux) was not installed in you system or not found by the MS ODBC driver installer.
Check your unixODBC version using odbc_config.
Edit:
Alright, I jumped through some hoops here.
The library libodbcinst.so.2 can be installed by installing the driver manager, as plhyhc suggested (basically running ./build_dm.sh from the same directory). Follow the instructions here: https://msdn.microsoft.com/en-us/library/hh568449(v=sql.110).aspx
I found an alternative way to install de odbc driver manager here: http://onefinepub.com/2014/03/installing-unixodbc-2-3-2-higher-ubuntu-12-04-lts/ in case microsoft's script fails (which it didn't for me).
Running odbc_config --version should tell you if the install failed (the command odbc_config will not be found if that is the case).
The missing libgss3 (A library for Generic Security Services) can be installed using apt:
sudo apt-get install libgss3
After that running ./install.sh verify didn't show any dependency errors for me anymore. And installed fine.
When I ran isql however (isql WebDB MyID MyPWD) it had another error for me: Can't open lib '/opt/microsoft/msodbcsql/lib64/libmsodbcsql-13.0.so.0.0, that library did exist, however when running ldd /opt/microsoft/msodbcsql/lib64/libmsodbcsql-13.0.so.0.0 I saw it still "misses" libodbcinst.so.2. Creating a symlink solved that problem for me:
sudo ln -s /usr/lib64/libodbcinst.so.2 /lib/x86_64-linux-gnu/libodbcinst.so.2
Original post:
I found this page: http://www.codesynthesis.com/~boris/blog/2011/12/02/microsoft-sql-server-odbc-driver-linux/
A little ways down he talks about what to do when libcrypto.so.6 and libssl.so.6 is not found. Apparently the versioning schemes for these libraries in RedHat EL are different then those for Ubuntu. He used symlinks to the equivalent libraries.
I realize these are not the libraries you found missing. But maybe you have equivalents? Maybe in /usr/lib?
I'm actually trying to get the odbc driver running myself too, if I find anything useful, I'll update this post.

How to install pgAgent service on windows

I am new in postgreSQL database , I recently found that postgreSQL support SQL Job by pgAgent. I am using windows XP operating system.
I searched lots about pgAgent on Google and trying to configure pgAgent on machine.
Download pgAgent package in which I found pgagent.sql file after executing this file JOB(0) icon is appear on my pgAdmin III object panel. like following image.
But I am facing problem to register pgAgent service. As per postgres sql documentation following is next steps to register services but I am fail to do this. or don't know how to configure pgAgent service.
Following step from postgre sql documentaion :
The service may be quite simply installed from the command line as follows:
"C:\Program Files\pgAdmin III\pgAgent" INSTALL pgAgent -u postgres -p secret hostaddr=127.0.0.1 dbname=pgadmin user=postgres
but I tried lot to do this, please help in how to register pgAgent service with Windows XP.
reference link of postgre sql : http://www.pgadmin.org/docs/1.6/pgagent-install.html
Please help in this , Thanks in Advance !
PgAgent is probably not installed
The pgAgent download page says:
pgAgent is a job scheduler for PostgreSQL which may be managed using
pgAdmin. Prior to pgAdmin v1.9, pgAgent shipped as part of pgAdmin.
From pgAdmin v1.9 onwards, pgAgent is shipped as a separate
application.
And then it provides a download link to http://www.postgresql.org/ftp/pgadmin3/release/pgagent/
But the problem is there's only source code there. There are also SQL files in the tarball but they're useless without pgagent.exe.
How to install it
Apparently the correct way to install a pre-compiled pgAgent is with the Stack Builder installer that also happens to be the primary installation method on Windows for the PostgreSQL server itself. That's what is suggested on the official download page:
http://www.postgresql.org/download/windows/
If you have already installed PostgreSQL for Windows with this method, the installer is available under the name Application Stack Builder in the PostgreSQL 9.2 folder in Windows Start Menu.
StackBuilder will normally recognize your installed PostgreSQL version(s), and suggest to install among various programs pgAgent in the Add-ons, tools and utilities category.
Once you check pgAgent and continue with the installation, it will download it and launch its setup. The setup phase includes runnning the necessary SQL statements and installing the PostgreSQL scheduling Agent - pgAgent windows service. If this step is successful, there is nothing else to do, the functionality will be available in pgAdmin for creating jobs.
What's misleading in the docs
The latest pgAdmin docs at http://www.pgadmin.org/docs/1.16/pgagent-install.html has a Service installation on Windows chapter that says:
The service may be quite simply installed from the command line as
follows (adjusting the path as required):
"C:\Program Files\pgAdmin III\pgAgent" INSTALL pgAgent -u postgres -p
secret hostaddr=127.0.0.1 dbname=postgres user=postgres
However in the majority of cases this is not going to be of help because either:
pgAgent install is done by pgAgent setup as launched by StackBuilder and this step is not necessary.
or you have got pgAdmin alone and pgagent.exe will not be installed so this step is not possible.
pgAdmin will be successfully installed after downloading the compressed file from
https://www.pgadmin.org/download/pgagent-source-code/
there inside, you will find the file "sql\pgagent.sql"
Toss the content of this file into the Query Tool and run it. That will install pgAgent. Refresh your database connection to see the result. The tab pgAgent Jobs should have been created at the root level for your connection.
There is no need of using the INSTALL command from your command line.
I faced the same problem. I was able to get pgagent working by downloading and executing the stand-alone installation file pgagent-3.4.0-4-windows.exe from here: http://sbp.enterprisedb.com/getfile.jsp?fileid=11842