How to deploy an existing VHD without any third party tool? - virtual-machine

I have created some VMs using Microsoft Hypervisor. I have the vhdx files for those VMs. now i want to use these same vhdx files to deploy new VMs on let's say other machines,or on the same machine with different names. IS it possible? If it is, Is it possible to deploy VHDs via a script?

I have not personally tried but through Windows PowerShell you can do it. Refer following links for more details:
https://www.starwindsoftware.com/blog/automate-the-hyper-v-virtual-machine-deployment-with-powershell
https://technet.microsoft.com/en-us/library/jj933287.aspx
https://www.altaro.com/hyper-v/hyper-v-attach-existing-virtual-disk/

Related

Grab bash script from an storage account and install in a Linux VMSS

I have a bash script in an azure storage account and I want to call that script from an Azure VMSS, when a new version of the script is available. Is this possible?
Thanks
Custom Script Extension can be used to run the script in VMSS.
The Custom Script Extension downloads and executes scripts on Azure virtual machines. This extension is useful for post deployment configuration, software installation, or any other configuration or management tasks. Scripts can be downloaded from Azure storage or GitHub, or provided to the Azure portal at extension run time. The Custom Script Extension integrates with Azure Resource Manager templates, and can be run using the Azure CLI, PowerShell, Azure portal, or the Azure Virtual Machine REST API.
It can be called on Virtual Machine Scaleset using Add-AzVmssExtension

Can I use NAS to access database on a network?

I want to ask if I can use NAS to store the main database like for example Firebird or MySQL and access this database from network ? if so how to install the database server software ?
Sure!
What's your nas model?
For example in my Synology i can enable web server and install mysql + phpmyadmin just in few clicks.
I just need to access in the admin panel and using the PacketManager start installing the software.
I'm sure it's possible to do the same with Qnap.
A "NAS" is simply Network Attached Storage. A personal example is the Western Digital My Cloud. You can use it to host the data files themselves, but no software can be installed.
There are networked solutions that are basically mini servers. They have slimmed down versions of a Linux build that run web servers, database servers and the like. I do not have any examples to provide since I do not have the need for one, but I know they are out there from prior research.
To learn about what a NAS is, you can check out the Wikipedia article.
NAS is basically just storage, it doesn't really run a useful OS. You need a server to host MySQL or similar DB. You can install MySQL on a Windows, Mac or Linux OS, the DB file(s) would reside on those machines and the MySQL services would respond to API requests appropriately. Here are some links to installing MySQL:
Windows - http://www.iis.net/learn/application-frameworks/install-and-configure-php-on-iis/install-and-configure-mysql-for-php-applications-on-iis-7-and-above
Linux - https://www.digitalocean.com/community/tutorials/how-to-install-linux-apache-mysql-php-lamp-stack-on-ubuntu

Importing database from an sFTP server in Windows Azure

I'm building a website that will surface data from a third party system. The third party will provide a copy of all the data I need as a SQL restore file (*.bak) inside a rar file on their sftp server. The data changes every day, so my application will need to connect to the sftp site, get the file, unzip it, then restore it into my database server every night. I'm fairly comfortable scripting this in a standard windows environment, but the customer would prefer the application to be built on the MS Azure cloud, which doesn't seem to support a common solution to the problem. It's possible we could abandon Azure, but I'd like to know what the best strategy would be for implementing in Azure if it's possible.
This depends on whether you are trying to use Azure PaaS (cloud service and SQL Azure) or IaaS (VMs). If you are using VMs on Windows Azure, there is going to be no difference between Windows Azure and your familiar Windows environment - so yes, you can do this on Windows Azure.
This can't really be done in Azure cloud services and SQL Azure (SQL Azure cannot restore a .bak file). But your application doesn't seem to be the kind that would run as a cloud service anyway.
Stick to doing it on VMs and it will work as you are familiar with.

Disk2vhd Hyper-V server question

Hello all I have a backed up about 30 servers using disk2vhd and now I have built my first of many hyper-v severs I did not realize this is all command line I did download CoreConfigurator and that does have some functionality I have been looking for. My question is how do I get the VHD files to run a Vitual Machines? its all command line I tried via vbs to mount the VHD's and I have not been able to any help on this would be great!
Thanks!
If you are using servercore, You maybe can do everything from the command line but I always prefer to have one computer running a Non server core version of windows 2008 to be the management server. You will load up Hyper-V manager on the non server core box and manage your Hyper-V server.
To have no "management" servers or desktops on your network will be a big pain IMO for management.
Using Hyper-V Manager you can quickly load the VHD's as VM's.
So load up Hyper-V Manager on a desktop PC on your localnet, and use its connect option to connect to your servercore. (Make sure your firewall settings are ok on servercore using coreconfig)

Copy files to a remote server via RDP using a script

We have a couple production servers that are configured to only allow access via RDP. There are no acessible shares. The dev team have no say in changing this setup but we want to automate code deployments to these machines. Presently we have to set Remote Desktop to share a local drive with the server, then RDP to the server and manually copy the deployment.
Any one know of a way to tunnel over RDP and drop files to a given directory on the remote host from the command line? The instructions will need to be included in an MSBuild configuration.
If you can get WS-MAN set up, PowerShell remoting and/or pmodem might be your ticket? https://web.archive.org/web/20180429054125/http://www.nivot.org/blog/2009/11/default