Skip to main content
IMHCloud Logo
Back to glossary

Instance

An instance is a virtual machine running on a cloud provider's infrastructure with its own operating system, CPU, memory, and storage that you can create, configure, and manage on demand.

What is an Instance in cloud hosting?

An instance is a virtual machine running on a cloud provider's infrastructure. It functions as a separate, isolated computer with its own operating system, CPU, memory, and storage. You create, configure, and manage instances just as you would physical servers, but without purchasing or maintaining hardware.

Each instance runs independently from other instances on the same physical hardware. You can start, stop, resize, or delete instances on demand, and you are typically charged based on how long the instance runs and the resources it consumes.

Why Instances Exist

Before cloud computing, running applications required purchasing, installing, and maintaining physical servers. This process was expensive, slow, and inflexible. If you needed more capacity, you had to buy new hardware and wait for delivery and setup. If you overestimated your needs, you wasted money on idle servers.

Instances solve this problem by decoupling compute resources from physical hardware. You can launch a new instance in minutes, scale up or down as demand changes, and pay only for what you use. This eliminates the upfront capital cost and reduces the time from planning to deployment.

What Do Instances Actually Do?

  • Runs an operating system and applications just like a physical server
  • Allocates dedicated CPU, memory, and disk resources from shared physical hardware
  • Connects to networks and receives IP addresses for communication
  • Starts, stops, and restarts on command without requiring physical access
  • Can be resized to a different flavor with more or fewer resources
  • Can be backed up by creating snapshots or images for recovery or replication
  • Gets billed based on runtime, resource allocation, or both, depending on the cloud provider's pricing model

When would I use an Instance?

You would use an instance when you need a dedicated environment to run an application, service, or workload. Common scenarios include:

  • Hosting a web application that requires its own operating system and software stack
  • Running a database server that needs consistent memory and CPU allocation
  • Setting up a development or testing environment that mirrors production infrastructure
  • Processing batch jobs or scheduled tasks that run periodically
  • Deploying containerized applications using orchestration tools like Kubernetes

You would also use instances when you need full control over the operating system, installed software, and system configuration, or when you want isolation from other users' workloads.

When would I not use an Instance?

You would not use an instance when a simpler or more cost-effective service meets your needs. For example:

  • Serverless functions: If your workload runs for short periods in response to events, serverless computing eliminates the need to manage instances and charges only for execution time.
  • Managed databases: If you only need database functionality, managed database services handle updates, backups, and scaling without requiring you to configure an instance.
  • Static websites: If your website consists of HTML, CSS, and JavaScript files with no server-side processing, object storage with static hosting is cheaper and faster than running an instance.
  • Lightweight tasks: If you need to run occasional scripts or small jobs, background task queues or scheduled functions may be more efficient than keeping an instance running.

You would also avoid instances when you cannot justify the cost of continuous operation, or when the overhead of managing operating system updates and security patches outweighs the benefit of full control.

Real-world example

Company A runs a customer-facing web application that handles variable traffic throughout the day. They need a reliable, scalable environment that can handle peak loads without over-provisioning during off-peak hours.

Company A creates multiple instances in their cloud provider's environment. Each instance runs Ubuntu with their web application stack installed. During business hours, they scale the number of instances up to handle increased traffic. During nights and weekends, they scale down to reduce costs.

By using instances instead of physical servers, Company A can respond to traffic changes in minutes rather than weeks. They avoid purchasing excess hardware for peak capacity and pay only for the compute time they actually use.

Frequently Asked Questions

Do I need more than one instance?

It depends on your availability and scaling requirements. A single instance works for small applications or development environments, but production workloads typically use multiple instances to avoid downtime if one fails. Using multiple instances behind a load balancer improves reliability and allows you to scale horizontally by adding more instances during high demand.

Does creating an instance affect existing resources?

No, creating a new instance does not change or interfere with other instances, networks, or storage. Each instance operates independently. However, creating many instances may consume quota limits set by your cloud provider, or increase network traffic if all instances share the same network resources.

What happens if I delete an instance?

Deleting an instance permanently removes its root disk and any local storage attached to it. You cannot recover data from a deleted instance unless you created a snapshot or attached persistent volumes. Attached volumes configured to persist after instance deletion will remain in your account, but you must explicitly delete them separately to stop incurring storage charges.

Can I change the size of an instance after I create it?

Yes, most cloud providers allow you to resize an instance by changing its flavor. This process typically requires stopping the instance, selecting a new flavor with different CPU, RAM, or disk allocations, and then restarting the instance. Some providers support live resizing for certain resource types, but most require downtime during the flavor change.

How do I access my instance after creating it?

You access your instance over the network using its assigned IP address. For Linux instances, you typically use SSH with a key pair for authentication. For Windows instances, you use Remote Desktop Protocol (RDP) with a username and password. The specific access method depends on the operating system you installed and the security group rules you configured to allow network connections.

Summary

  • An instance is a virtual machine running on cloud infrastructure with dedicated CPU, memory, and storage
  • Instances replace physical servers by providing on-demand compute resources that you can start, stop, and resize as needed
  • You use instances when you need full control over the operating system and application environment, or when you require isolation from other workloads
  • Instances charge based on resource allocation and runtime, making them cost-effective for variable workloads compared to always-on physical hardware
  • For simpler use cases like static websites or short-lived tasks, alternative services like serverless functions or managed platforms may be more efficient than managing instances

Related terms

  • Flavor (predefined resource template): A template that defines the CPU, RAM, and disk allocation for an instance, such as "2 vCPUs, 4GB RAM, 20GB disk."
  • Image (operating system template): A pre-configured operating system and software package used to launch an instance, such as Ubuntu 22.04 or CentOS 9.
  • Volume (block storage): A persistent disk you can attach to an instance for additional storage that survives instance deletion, such as a 100GB data volume for a database.
  • Snapshot (point-in-time backup): A complete copy of an instance or volume at a specific moment, such as a backup taken before a software upgrade.
  • Security Group (firewall ruleset): A set of network rules that control which traffic can reach or leave an instance, such as allowing SSH on port 22 from specific IP addresses.

Related Terms

Read definition

OpenStack API

The OpenStack API is a collection of RESTful HTTP interfaces that allow applications and tools to programmatically manage cloud resources including instances, networks, storage, and identity services.

Infrastructure
Learn more
Read definition

Multi-Tenancy

Multi-tenancy is a cloud architecture where multiple customers share the same physical infrastructure while remaining logically isolated from each other, enabling efficient resource utilization and cost sharing.

Infrastructure
Learn more
Read definition

Glance

Glance is the OpenStack image service that stores, catalogs, and retrieves disk images used to launch instances in a cloud environment.

Storage
Learn more
Read definition

Project

A project is an isolated resource container in OpenStack that groups users, instances, networks, storage, and other cloud resources under a single administrative boundary with defined quotas and access controls.

Infrastructure
Learn more
Read definition

Usage-Based Billing

Usage-based billing is a pricing model where customers pay only for the cloud resources they actually consume rather than a fixed monthly fee.

Cost Management
Learn more